Palette taglib ver. 1.2

    Custom JSP tag. This taglib lets you output a color palette for HTML.

For example:
 


<%@ taglib uri="taglib.tld" prefix="p" %>

<p:Palette width="15px" height="10px" onClick="f1" />

<script language="JavaScript">

function f1(color) { alert(color); }

</script>

and you will get some like this

:
                  
                  
                  
                  
                  
                  
                  
                  
                  
                  
                  
                  

Tags are:

Palette

Outputs HTML color palette. Parameters are:

1) width Optional parameter. Defines a width for cells in your palette. Default value is 10px.
2) height Optional parameter. Defines a height for cells in your palette. Default value is 10px.
1) onClick Optional parameter. Defines a name for JavaScript function processes the clicks on cells. By default tag changes the color for the whole document.
 

for downloading:

    Library: palettetag.jar    Description: taglib.tld

 © Coldbeans      Comments?

See also Coldtags suite - the largest collection of custom JSP tags.

Related links: