Home Articles FAQs XREF Games Software Instant Books BBS About FOLDOC RFCs Feedback Sitemap
irt.Org
#

Q35 How do I get the x,y position of the image clicked to return?

You are here: irt.org | FAQ | JavaScript | Image | Q35 [ previous next ]

<a href="thisdocument.html"><img src="image.gif" border="0" ismap></a>

<script language="JavaScript"><!--
str = location.search;
if (str == "")
    document.write("<p>No coordinates specified.");
else {
    commaloc = str.indexOf(",");
    document.write("<p>The x value is " + str.substring(1, commaloc));
    document.write("<p>The y value is " + str.substring(commaloc+1, str.length));
}
//--></script>

Feedback on 'Q35 How do I get the x,y position of the image clicked to return?'

©2018 Martin Webb