kod plugin u w html
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html> <head> <link rel="stylesheet" href="farbtastic.css" type="text/css"/> <style type="text/css" media="screen"> .colorwell { border: 2px solid #fff; width: 6em; text-align: center; cursor: pointer; } body .colorwell-selected { border: 2px solid #000; font-weight: bold; } </style> <script type="text/javascript" charset="utf-8"> $(document).ready(function() { $('#demo').hide(); var f = $.farbtastic('#picker'); var p = $('#picker').css('opacity', 0.25); var selected; $('.colorwell') .each(function () { f.linkTo(this); $(this).css('opacity', 0.75); }) .focus(function() { if (selected) { $(selected).css('opacity', 0.75).removeClass('colorwell-selected'); } f.linkTo(this); p.css('opacity', 1); $(selected = this).css('opacity', 1).addClass('colorwell-selected'); }); }); </script> </head> <body> <form action="" style="width: 500px;"> </form> </div> </body> </html>
kod mojej strony testowej
css
@charset "utf-8"; /* CSS Document */ #wrappez {width: 1000px; height: auto; margin-top: 0px; margin-bottom: 0px; margin-left: auto; margin-right:auto} nav {width: 1000px; height: 50px; background: red; float: left} #slider {width: 1000px; height: 300px; background: black; float: left} #left {width: 200px; height: 300px; background: yellow; float: left} #srodek {width: 800px; height: 300px; background: red; float: left} #right {width: 200px; height: 300px; background: yellow; float: left} footer {width: 1000px; height: 50px; background: black; float: left} a:hover {color: wight} a:active {color: blou} a:visited {color: black} a: {color: red; display: block}
reszta w pliku rar
farbtastic.zip