复制代码代码如下:
função find_select (nome)
{
var select = document.getElementsByName (nome);
var find_str = document.getElementById ('to_find_str').
se (selecionar)
{
selecione = selecione [0];
var filho = select.ChildNodes;
var pode = false, text = '', len = child.length, is_end = true;
for (var i = 0; i <len; i ++)
{
se (lata)
{
texto = criança [i] .text;
if (texto &&
text.indexOf (find_str)! =-1)
{
//console.log(Text);
criança [i] .Selected = true;
var V = criança [i] .Value;
select.value = v;
select.onchange (v);
is_end = false;
quebrar;
}
}
if (criança [i].
pode = true;
}
if (is_end)
alerta ('' ');
}
}
复制代码代码如下:
<tr>
<td> <? php echo $ l_specialActivityIdentifier?> </td>
<Td>
<select name = "Atividade [identificador]" id = "identificador" onchange = "change_activity (this.value)">
<opção value = ""> 请选择 </pption>
<? php
foreach ($ ActivityTypes como $ row) {
echo '<opção value = "'. $ row ['identificador']. '". . $ Row ['nome']. '</pption>';
}
?>
</leclect>
-<Valor de entrada = '' id = 'to_find_str' size = 16 style = "text-align: Center;" /> <Valor de entrada = 'find' onclick = 'find_select ("atividade [identificador]")' tipo = botão />
</td>
</tr>