Here's my HTML:
<input type='checkbox' name='PatientReady1' value='Yes' checked onClick="PatientReady ("PatientReady1","111","PatientReady")">
And my javascript:
function PatientReady(element, TriageNo, Field){
debugger;
if (element.checked == 1){
new Ajax.Request (
"PatientReady.asp",
{
method: 'post',
parameters: {
TriageNo: TriageNo,
strReady: "Yes",
strElement: Field
},
asynchronous:false
}
);
}
else{
new Ajax.Request (
"PatientReady.asp",
{
method: 'post',
parameters: {
TriageNo: TriageNo,
strReady: "No",
strElement: Field
},
asynchronous:false
}
);
}
}
For some reason I'm getting a syntax error, when I click on the checkbox... I'm sure I'm missing some tiny stupid thing, perhaps a fresh set of eyes can help?