Folge dem Video um zu sehen, wie unsere Website als Web-App auf dem Startbildschirm installiert werden kann.
Anmerkung: Diese Funktion ist in einigen Browsern möglicherweise nicht verfügbar.
return_reason_+i
if(document.all_data.elements['return_reason_'+i].options[document.all_data.elements['return_reason_'+i].selectedIndex].value == "no_selection")
if(document.all_data.elements['return_reason_'+i].value == "no_selection")
<td bgcolor="effaff"><b>Return reason:</b></td>
<td bgcolor="effaff"><select name="return_reason_<?=$count_id?>" style="width: 200px">
<option name="select_<?=$count_id?>" value="no_selection">- Select -</option>
<option value="Doesnt like">Doesnt like</option>
<option value="Damaged">Damaged</option>
</select></td>
function chkForm() {
for(i=0; i < document.items.elements.length; i++) {
if(document.items.elements[i].checked) {
if(document.all_data.elements['return_reason_'+i].value == "no_selection") {
alert("Felder!");
return false;
}
}
}
}
while($test = mysql_fetch_object($re))
{
$count_id++;
<form name="all_data" action="" method="post" onSubmit="return chkForm()">
...
<td bgcolor="effaff"><b>Return reason:</b></td>
<td bgcolor="effaff"><select name="return_reason_<?=$count_id?>" style="width: 200px">
<option name="select_<?=$count_id?>" value="no_selection">- Select -</option>
<option value="Doesnt like">Doesnt like</option>
<option value="Damaged">Damaged</option>
</select></td>