Klaus Hartl wrote:
seedy wrote:
When I try to use a wildcard to search for characters in an onclick
attribute
it doesnt appear to work.
I think this syntax is correct
$('input:[EMAIL PROTECTED]')
I know there is a bug with onclick in 1.1.3.1, is this somehow related?
I assume that you can't just parse the content of the onclick attribute,
as in this special case what's in there becomes a javascript expression
and not simple text...
Try:
$('input:image').each(function() {
alert(typeof this.onclick);
});
It should alert "function".
From the HTML spec:
Script data ( %Script; in the DTD) can be the content of the SCRIPT
element and the value of intrinsic event attributes. User agents must
not evaluate script data as HTML markup but instead must pass it on as
data to a script engine.
http://www.w3.org/TR/html401/types.html#type-script
--Klaus