Hi guys,
I have 5 radio buttons (NONE of these are pre-selected).
Basically, if someone doesn't enter a rating... then I need it to pop up an alert. I know the other 2 subroutines are working fine... but this new one just doesn't seem to report an error back :/
The code is;
alert( "You need to set a Rating for this piece of work!");
return false;
}
The radio buttons HTML looks like;
<input type="radio" value="2" name="EditorRating">2
<input type="radio" value="3" name="EditorRating">3
<input type="radio" value="4" name="EditorRating">4
<input type="radio" value="5" name="EditorRating">5
One of the subs that works is ;
alert( "You need to set a Title for this piece of work!");
main.ChangedTitle.focus();
return false;
}
Could this have something to do with using the radio buttons? AFAIK, these are supported in Javascript?
TIA
Andy (mod)
andy@ultranerds.co.uk
IMPORTANT: I've now moved to ultranerds.co.uk, and the .com will no longer work!
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package (plugins total "value" $3,325 & rising, for just $350)| GLinks ULTRA Package PRO (plugins total "value" $5,625 & rising, for just $500)
Support Forum | Links SQL Plugins | DMOZ Dumps | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Compare our different Plugin packages *new* Free CSS Templates
I have 5 radio buttons (NONE of these are pre-selected).
Basically, if someone doesn't enter a rating... then I need it to pop up an alert. I know the other 2 subroutines are working fine... but this new one just doesn't seem to report an error back :/
The code is;
Code:
if (main.EditorRating.value == "" && main.DeleteReason.value == "") { alert( "You need to set a Rating for this piece of work!");
return false;
}
The radio buttons HTML looks like;
Code:
<input type="radio" value="1" name="EditorRating">1 <input type="radio" value="2" name="EditorRating">2
<input type="radio" value="3" name="EditorRating">3
<input type="radio" value="4" name="EditorRating">4
<input type="radio" value="5" name="EditorRating">5
One of the subs that works is ;
Code:
if (main.ChangedTitle.value == "" && main.DeleteReason.value == "") { alert( "You need to set a Title for this piece of work!");
main.ChangedTitle.focus();
return false;
}
Could this have something to do with using the radio buttons? AFAIK, these are supported in Javascript?
TIA
Andy (mod)
andy@ultranerds.co.uk
IMPORTANT: I've now moved to ultranerds.co.uk, and the .com will no longer work!
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package (plugins total "value" $3,325 & rising, for just $350)| GLinks ULTRA Package PRO (plugins total "value" $5,625 & rising, for just $500)
Support Forum | Links SQL Plugins | DMOZ Dumps | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Compare our different Plugin packages *new* Free CSS Templates

