最新下载
热门教程
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
取得input中部分选中(selected)的值
时间:2022-07-02 12:50:17 编辑:袖梨 来源:一聚教程网
取得input中部分选中(selected)的值(for IE and Firefox),这个例子非常不错,给大家共享一下。
| 代码如下 | 复制代码 |
| function Preview(obj) { var TestWin=open(''); TestWin.document.write(obj.value); } function copyCode(obj) { var rng = document.body.createTextRange(); rng.moveToElementText(obj); rng.scrollIntoView(); rng.select(); rng.execCommand("Copy"); rng.collapse(false); } function saveCode(obj) { var winname = window.open('', '_blank', 'top=10000'); winname.document.open('text/html', 'replace'); winname.document.writeln(obj.value); winname.document.execCommand('saveas','','homepage..htm'); winname.close(); } function addBookmark(title,url) { if (window.sidebar) { window.sidebar.addPanel(title, url,""); } else if( document.all ) { window.external.AddFavorite(url,title); } else if( window.opera && window.print ) { return true; } } onmouseup="javascript:a()" /> |
|
运行代码复制代码另存代码收藏本页
相关文章
- 漫蛙manwa2-官网最新入口 03-06
- 蜜桃国产剧TV高清在线入口-蜜桃全网永久免费观看入口 03-06
- 麻花豆国产剧高清在线播放-麻花豆国产剧畅享免费mv 03-06
- 高德地图网页版入口-高德地图网页版在线体验 03-06
- AO3中文网入口在哪-2026最新AO3备用网址速递 03-06
- 樱花漫画官网入口在哪里?2026亲测可用稳定访问链接 03-06