Home >Web Front-end >JS Tutorial >A select written in javascript supports the functions of up and down keys, initial letter filtering and carriage return to get values_javascript skills

A select written in javascript supports the functions of up and down keys, initial letter filtering and carriage return to get values_javascript skills

WBOY
WBOYOriginal
2016-05-16 18:46:521657browse

It can be called like this:

1, tempStr=GetNewSelectStr(dataTable.value,"select" rowIndex,true);
2,makeSelectBox("select" rowIndex,tempStr,value,obj);

tempStr - This is the frame of the returned drop-down list value
dataTable.value - This is the data source (I am a table here)
"select" rowIndex - This is the ID number, that is The ID number of the current select (I have multiple selects here, so the ID number is automatic)
true - this is the identifier that controls the drop-down box that appears when clicked
value - this is initially displayed in The value in the select input box
obj - this is the object to display the select

Source code:

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn