Forum Moderators: open
<script type="text/javascript"
src="http://yui.yahooapis.com/2.8.0r4/build/yahoo-dom-event/yahoo-dom-event.js"></script>
<script type="text/javascript">
var xy = YAHOO.util.Dom.getXY('myElement');
// xy is now an array with the x and y values
</script>
I would start by fixing your id values. Even if you just add a single letter before the number, so "1", "2", "3", ..., might become "i1", "i2", "i3",...
Next:
var checkNow = "i" + checking; // instead of new String
Next:
var check = YAHOO.util.Dom.getXY(checkNow);
// No need to convert to string, then back to array