运用jquer的colorpicker.js插件实现点击文本框显示颜色选择器
<script type="text/javascript" src="jquery.js"></script> <script type="text/javascript" src="jquery.colorpicker.js"></script> 请输入颜色值:<input type="text" id="txt1" /> </div> <script type="text/javascript"> $(function(){ $("#txt1").colorpicker({ fillcolor:true }); }); </script>