I have a function moveDiv(divID).
to test to see if the div has moved far enough:
if (new_left < 400)
{
the_timeout = setTimeout("moveDiv("myDiv");",10);
}
WORKS but this DOESN'T
if (new_left < 400)
{
the_timeout = setTimeout("moveDiv(divID);",10);
}
nor does this:
if (new_left < 400)
{
the_timeout = setTimeout("moveDiv("+divID+");",10);
}
nor does this:
if (new_left < 400)
{
the_timeout = setTimeout("moveDiv(this);",10);
}
how do I tell this statement to evaluate the argument 'divID'????????
The only way it works is if I give it the actual name of the div. I
have messed endlessly with the syntax and NOTHING works.