当前位置: 首页 > 图文教程 > 网络编程 > Javascript > 打造个性化的Select(可编辑)

Javascript
form中限制文本字节数js代码
use jscript with List Proxy Server Information
use jscript List Installed Software
List Installed Software Features
List Information About the Binary Files Used by an Application
List the Codec Files on a Computer
List the UTC Time on a Computer
List Installed Hot Fixes
excel操作之Add Data to a Spreadsheet Cell
Add Formatted Data to a Spreadsheet
Apply an AutoFormat to an Excel Spreadsheet
JavaScript语法着色引擎(demo及打包文件下载)
类之Prototype.js学习
一款JavaScript压缩工具:X2JSCompactor
iis6+javascript Add an Extension File
jscript之Open an Excel Spreadsheet
jscript之Read an Excel Spreadsheet
jscript之List Excel Color Values
去除图像或链接黑眼圈的两种方法总结
Add a Formatted Table to a Word Document

Javascript 中的 打造个性化的Select(可编辑)


出处:互联网   整理: 软晨网(RuanChen.com)   发布: 2009-09-12   浏览: 220 ::
收藏到网摘: n/a

由于系统自带的Select实在是不好用,这里我用javascript写了一个全新的Select.
功能:
1.可编辑的Select
2.长度可以随意修改
3.可以遮盖系统Select
4.支持forms
5.支持CSS修改外观
6.修正在IE 5.0上运行出错的问题
7.支持使用js脚本
使用方法
[b]var 实体化变量=new editselect(名字,长度,默认字符串,宽度,高度,只读)[/b]
[b]实体化变量.add(option数值,JS脚本)[/b]
这只是一个测试版,很多功能没有完善,比如没有区分value和caption等等,希望大家提出宝贵意见.
点击运行可以看到效果:
[Ctrl+A 全选 提示:你可先修改部分代码,再按运行]