dance621
11-18-2006, 08:15 AM
Hi, I asked a question yesterday about replacing " with ' in my script because it needs to be exported in csv and csv hates ". Felgall helped and said I can use ' and \'. However, there are instances in the script where I need an extra level of nesting (third level). Actually the script at that point involves some javascript also. Is there a way of writing this so that I do not need any quotes ("). I played around but could get anything to work. I also cannot call remote scripts which is a pain because life would have been a lot easier!
Here is the bit that needs to be without quotes...
<TD vAlign=top width=45><div class="pic"><A href="#topanchor"
onclick="
imagew1.src='http://hardyart.co.uk/frame/wall1.jpg';
bselw.src='http://www.hardyart.co.uk/frame/selectwall.gif';
bselft.src='http://www.hardyart.co.uk/frame/selectframetext.gif';
bselomt.src='http://www.hardyart.co.uk/frame/selectoutmounttext.gif';
bselst.src='http://www.hardyart.co.uk/frame/selectsliptext.gif';
document.getElementById('imagew1').style.backgroundImage =
'url(\'http://hardyart.co.uk/frame/wall1s.jpg\')';">
<IMG name=imagewi1 src="http://hardyart.co.uk/frame/wall1.jpg" Title="Pure white" border=0></A></div></TD>
Any ideas?
I think this below was my best attempt but still didnt like it (invalid character which must be the slosh-quote?...
<TD vAlign=top width=45><div class='pic'><A href='#topanchor'
onclick='
imagew1.src=\'http://hardyart.co.uk/frame/wall1.jpg\';
bselw.src=\'http://www.hardyart.co.uk/frame/selectwall.gif\';
bselft.src=\'http://www.hardyart.co.uk/frame/selectframetext.gif\';
bselomt.src=\'http://www.hardyart.co.uk/frame/selectoutmounttext.gif\';
bselst.src=\'http://www.hardyart.co.uk/frame/selectsliptext.gif\';
document.getElementById(\'imagew1\').style.backgroundImage =
\'url(http://hardyart.co.uk/frame/wall1s.jpg)\';'>
<IMG name=imagewi1 src='http://hardyart.co.uk/frame/wall1.jpg' Title='Pure white' border=0></A></div></TD>
Thanks! James
Here is the bit that needs to be without quotes...
<TD vAlign=top width=45><div class="pic"><A href="#topanchor"
onclick="
imagew1.src='http://hardyart.co.uk/frame/wall1.jpg';
bselw.src='http://www.hardyart.co.uk/frame/selectwall.gif';
bselft.src='http://www.hardyart.co.uk/frame/selectframetext.gif';
bselomt.src='http://www.hardyart.co.uk/frame/selectoutmounttext.gif';
bselst.src='http://www.hardyart.co.uk/frame/selectsliptext.gif';
document.getElementById('imagew1').style.backgroundImage =
'url(\'http://hardyart.co.uk/frame/wall1s.jpg\')';">
<IMG name=imagewi1 src="http://hardyart.co.uk/frame/wall1.jpg" Title="Pure white" border=0></A></div></TD>
Any ideas?
I think this below was my best attempt but still didnt like it (invalid character which must be the slosh-quote?...
<TD vAlign=top width=45><div class='pic'><A href='#topanchor'
onclick='
imagew1.src=\'http://hardyart.co.uk/frame/wall1.jpg\';
bselw.src=\'http://www.hardyart.co.uk/frame/selectwall.gif\';
bselft.src=\'http://www.hardyart.co.uk/frame/selectframetext.gif\';
bselomt.src=\'http://www.hardyart.co.uk/frame/selectoutmounttext.gif\';
bselst.src=\'http://www.hardyart.co.uk/frame/selectsliptext.gif\';
document.getElementById(\'imagew1\').style.backgroundImage =
\'url(http://hardyart.co.uk/frame/wall1s.jpg)\';'>
<IMG name=imagewi1 src='http://hardyart.co.uk/frame/wall1.jpg' Title='Pure white' border=0></A></div></TD>
Thanks! James