Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

` can be used in place of single or double quotes around attribute values in IE.


My understanding (and I tested to confirm) is that IE only treats ` as an attribute delimiter when it's assigned to an element's innerHTML value dynamically. So this is important when working with client-side code, but not so much when generating HTML on the server.

Am I wrong?


I just tried the following HTML:

    <input type="text" value=`asdf` />
In IE, the input box contained the string asdf. In other browsers, it contained the string `asdf`


You're right. I was mistakenly testing only a limited case (described at http://html5sec.org/#59). Thanks!




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: