Page is a not externally linkable
- Code, Content, and Presentation
-- HTML
---- onclick varies between browsers


Fotiman - 1:42 pm on Sep 24, 2012 (gmt 0)


The following works for me in all browsers:

<html>
<head>
<title>
Test
</title>
</head>
<body>
<form action="">
<div>
<INPUT TYPE="radio" name="radiobuttons" id="radiobutton3" VALUE=0 onClick="f_button()">
</div>
</form>
<script>
function f_button() {
alert("hello");
}
</script>
</body>
</html>

Note, however, that I would not use inline event handlers. Instead, attach event listeners via the script code... don't muddle your HTML with scripting content.
Also, you should consider cleaning up your code with respect to what lucy24 pointed out. You've got mixed case, and inconsistent use of quotes around HTML attribute values. Your code should look more like this when cleaned up:


<input type="radio" name="radiobuttons" id="radiobutton3" value="0" onclick="f_button();">


Thread source:: http://www.webmasterworld.com/html/4498848.htm
Brought to you by WebmasterWorld: http://www.webmasterworld.com