snowboardalliance
Can someone show me a function that can find out what id was clicked and make something like div.something#20 visible. Like, if I have a grid of div's with different ids, can I have a surrounding div use onclick to find the id of a div within it? Also, when the information is shown, it should make the last div it made invisible first, so only one shows at a time.
I don't know if this is all clear, but basically, I want javascript that will print out something different for each square in a grid, only showing one at a time.
I really appreciate any help I can get because I don't reall know javascript.
Edit: now that I think about it, would it be better to just use a php page in an iframe, and use links like info.php?id=20? This would mean I only get all the database info when it is needed. But I'll wait for a response.
I don't know if this is all clear, but basically, I want javascript that will print out something different for each square in a grid, only showing one at a time.
I really appreciate any help I can get because I don't reall know javascript.
Edit: now that I think about it, would it be better to just use a php page in an iframe, and use links like info.php?id=20? This would mean I only get all the database info when it is needed. But I'll wait for a response.
