Hi there,
I am having a problem creating an onmouseover dynamically using XSL. Please be gentle with me, I suspect this may be a newbie being foolish!
Where ever I use {} notation in my XSL the resulting HTML is broken on to three lines, this isn't a problem with HTML, but now I need to include an onmouseover on an image with an XSL variable as a parameter and I am gettting Unterminated String Literal errors. Snippet of code below along with the snippet of resulting HTML, can supply entire code, but suspect an expert will be able to tell me how stupid I'm being!!
Code:
<td valign="middle">
<div align="center">
<img src="../uploadeddata/{../Product[position()=$p+$h]/MainImage}" alt="{../Name}" align="middle" onMouseover="ddrivetip('{../Product[position()=$p]/MainImage}')"
onMouseout="hideddrivetip()"/>
</div>
</td>
------ Result ------------
<td valign="middle"><div align="center"><img src="../uploadeddata/
TG242A.jpg
" alt="" align="middle" onMouseover="ddrivetip('
TG476A.jpg
')" onMouseout="hideddrivetip()"></div></td>
</tr>
<tr>
--------End Result ---------
As you can see the
Code:
onMouseover="ddrivetip('TG476A.jpg')"
needs to be on one line, but it seems the {} are breaking it on to 3 lines.
Any help would be appreciated, have been turning the internet upside down to fix this one!!!
Al