在IE6中使用5000个选项创建选择标记的最快方法是什么? [英] What is the fastest way to create a select tag with 5000 options in IE6?
本文介绍了在IE6中使用5000个选项创建选择标记的最快方法是什么?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
可用性:在IE6中使用5'000 选项
元素创建 select
标记的最快方法是什么来自JavaScript?
Usability aside: What is the fastest way to create a select
tag with 5'000 option
elements in IE6 from JavaScript?
推荐答案
短测:
- 首先收集innerHTML字符串并将其注入文档: 300ms
- 使用新的Option()将选项附加到现有的select元素: 约25秒
- Collecting a innerHTML-string first and inject it to the document: around 300ms
- appending options to an existing select-element using new Option(): around 25 sec
这篇关于在IE6中使用5000个选项创建选择标记的最快方法是什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文