Is there anyway by which i can use the $ or $$ utility selectors with arguments containing special characters?
<div id="my example">
$('my example')
<div class="item1\item2">
$$('div.item1\item2')
I've tried开发者_如何学编程 using the standard escape sequence \ but am having no luck.
Arguments to those functions can contain id
s of elements. As the spec says:
ID and NAME tokens must begin with a letter ([A-Za-z]) and may be followed by any number of letters, digits ([0-9]), hyphens ("-"), underscores ("_"), colons (":"), and periods (".").
This implies that special characters within id
s are not allowed.
精彩评论