Nesting quotes in JavaScript/HTML -
How do you nest out of the second level in HTML? As far as I know, there are only two types of quotes - single (') and double ("). I have the information to avoid using slash - you have to run in the code, but avoiding the browser level did not work What is the acceptable method to get something similar to the following?
'); "> Some text
You must use the appropriate escape / encoding either in HTML Use the character references:
& lt; p onclick = "exampleFunc ('& amp; Lead; div id = & amp; quot; divId & amp; quot; & amp; Gt; & amp; lt; / div & gt; ');
"ExampleFunc ('\ x3Cdiv \ x20id \ x3D \ x22divId \ x22 \ x3E \ X3C / div \ x3E'); "& Gt; some text & lt; / p & gt;
Comments
Post a Comment