jQuery will read it as id "test2" with the class "3"

While periods are allowed in the attribute I would advise against them, as it's not just jQuery that could struggle with them but most CSS as well, as #test2.3 with again read as id "test2" with the class "3".

Finn Herpich wrote:
Hi everyone,

the attached example-code shows a problem I encountered today (firebug needed).

If an id-attribute contains dots, like
<p id="test2.3"></p>
 jQuery isn't able to find it.
If the dots are replaced by underscores everything works fine.

Afaik there is no limitation for the id which prohibit dots as a used symbol, so I guess this is a bug or for some reason not wanted?

Cheers

Reply via email to