Color picker

[ POLSKI ]

While seeking a simple and easy to use color picker component we found the ParanoidFerret website. Their solution is nice, but we enhanced it a bit. This way our Color picker was made. The original version was about 74 kB and it was not possible to attach it to an editbox. We squeezed the whole thing into 20 kB and included some new features. You can test the component here.

Color Picker

To use the component you need to add a few elements to your page:

1. In the head section add:


<script type="text/javascript">
function pickcolor(elm)
 {
 window.open('colorpicker/colorpicker.htm#'+elm.id, 
          '',
	  'location=0,status=0,scrollbars=0,width=550,height=305');
 }
</script>

2. For the chosen editbox (<input type="text">) attach the colorpick function.
Notice! Every editbox should have its own unique ID.


<input type="text" id="t2" onclick="pickcolor(this)">

Of course we can attach the component to many editboxes:


<input type="text" id="field1" onclick="pickcolor(this)">

<input type="text" id="field2" onclick="pickcolor(this)">

Version:1.0 Size:20,3 kB
(23,7 kB uncompressed)
Autors:Paranoid Ferret, Walidator.info License:BSD License
Normal
version:
Pobierz Uncompressed
version:
Pobierz

Co myślisz o naszej stronie?








Polecamy:

Royalty Free Images

toner Nashuatec
pozycjonowanie
usługi prawne Warszawa
architektura wnętrz
buty damskie
Copyright © 2007-9 by walidator.info. Odwiedzin: 80991