Justin French wrote:
<div onmouseover="myFunc('foo','bah')">...</div>
will break terribly when converted to
<div onmouseover='myFunc('foo','bah')'>
This might actualy not be such a big problem if you HTMLEncodes your inline javascript.
This seems to work in IE 6, FF 0.8, OP 6 and NN 4.7 (win)
<a href="javascript: alert("test");">test</a>
<a href="#" onclick="alert("test");return false;">test</a>
<a href='javascript: alert("test");'>test</a>
<a href='#' onclick='alert("test");return false;'>test</a>
<a href="javascript: alert('test');">test</a>
<a href="#" onclick="alert('test');return false;">test</a>
<a href='javascript: alert('test');'>test</a>
<a href='#' onclick='alert('test');return false;'>test</a>
Personaly, I would recommend using an external .js file.
--
Kristof
*****************************************************
The discussion list for http://webstandardsgroup.org/
*****************************************************
