PDA

View Full Version : how to remove a div element?


joeframbach
12-25-2002, 01:48 AM
im still working on my paintball game... and no luck in either of three forums (this one, webxpertz.net, and programmersheaven.com)

so, im trying something else. maybe i'll get help if i ask easier questions.

how do i completely remove a <DIV> created in the <body>?
i have a form in a div that needs to be filled out, then uses the information to make player objects for the game. the div is done at this point. the user has no need, and neither do i, for the div. how do i get rid of it?

jkd
12-25-2002, 01:58 AM
refToDiv.parentNode.removeChild(refToDiv)

joeframbach
12-25-2002, 05:20 AM
thank you very very much