PDA

View Full Version : javascript


phani
11-21-2002, 02:00 PM
Hi,

how to compare the value of a div tag in the javascript, i need to ensure that the id belongs to the div tag only. what i mean i want to compare all the id of the div tags and if the id is equal to required value i want to execute the code with in the div tag

can i use div.id="tabluran"

beetle
11-21-2002, 02:31 PM
Something like this?

var d = document.getElementById('tabluran')';

Oh, and try to use a more descriptive topic next time...'javascript' just doesn't let the reader know what the subject of the post is....

landon11
11-21-2002, 02:33 PM
You can use:

document.getElementById("divId")

[Edit]

Yeah, what Bettle said.