How do I add an OnMouseUp event to an ASP.Net Anchor tag with dynamic information in it?
I have an anchor tag and when clicked I want another window to open using Javascript. The problem I am having is that the usual format of:
onMouseUp="window.open('showImage.aspx?imageID=','popup', 'height=10, width=10, toolbar=no, menubar=no, status=no')"
Only works if there is no dynamic information in it. I want imageID in the URL to be dynamic. I have tried the following but it doesn't work as it keeps telling me my tag is improperly formed:
onMouseUp="window.open('showImage.aspx?imageID="& <%# Container.DataItem("eyewearID") %> &"','popup', 'height=10, width=10, toolbar=no, menubar=no, status=no')"
Any ideas?
Thanks in advance,
Chris
I have an anchor tag and when clicked I want another window to open using Javascript. The problem I am having is that the usual format of:
onMouseUp="window.open('showImage.aspx?imageID=','popup', 'height=10, width=10, toolbar=no, menubar=no, status=no')"
Only works if there is no dynamic information in it. I want imageID in the URL to be dynamic. I have tried the following but it doesn't work as it keeps telling me my tag is improperly formed:
onMouseUp="window.open('showImage.aspx?imageID="& <%# Container.DataItem("eyewearID") %> &"','popup', 'height=10, width=10, toolbar=no, menubar=no, status=no')"
Any ideas?
Thanks in advance,
Chris