16
May 08
This plugin has been developed by me when I start to create this site, with a lot of colors manipulations
I decided to write a group of functions and after that I transform it to a plugin. So feel free to use it.
Download it here: jQuery.Colors (5.43 KB) - 265 hits
Usage example:
| 1 | |
| 2 | var Light = $.color(235, 235, 235); |
| 3 | var Dark = $.tocolor("#ffa500"); |
| 4 | var GradLinkNormal = $.colorgrad(Light, Dark, 10); |
| 5 | |
Will result in a array with ten diferent colors, like this:
|
|
code:
| 01 | | | 02 | <script language="JavaScript"> | | 03 | var Light = $.color(235, 235, 235); | | 04 | var Dark = $.tocolor("#ffa500"); | | 05 | var GradLinkNormal = $.colorgrad(Light, Dark, 10); | | 06 | for(i = 1; i <= 10; i++){ | | 07 | document.write("<div style='background:" + | | 08 | GradLinkNormal.grad(i).hexHTML() + ";width:100px;padding:3px 3px;'>" + | | 09 | GradLinkNormal.grad(i).hexHTML() + "</div>"); | | 10 | } | | 11 | </script> | | 12 | |
|
This entry was posted
on Friday, May 16th, 2008 at 1:02 pm and is filed under news.
You can follow any responses to this entry through the RSS 2.0 feed.
You can leave a response, or trackback from your own site.
news — 2 comments
This is a fantastic tool, Gilberto! Thank you so much for sharing. The site looks great, by the way.
Eye Calamba…. aye yuh have it man… I would like to see this work as on gradient text.