Hi,
I use document.write in a HTML-document to display same information. Now I
have a problem displaying text that sometimes contains two kinds of quotes
simultanelisly. I don't know on beforehand if this is the situation. See
example:
## ---
<script language="JavaScript">
var a1; // text to display - variable between '
var a2; // text to display - variable between "
a1='This text (a1) contains the single (') and the double (") quote and is
placed between single quotes. How can I display this variable using
document.write?'
a2="This text (a2) contains the single (') and the double (") quote and is
placed between double quotes. How can I display this variable using
document.write?"
document.write(""+a1+" "+a2+"");
</script>
## ---
Is there possibly another character to use for placing around the text? Or
any other solution?
Thanks,
Sjoerd