vomitcomet Posted April 28, 2011 Share Posted April 28, 2011 For my school project, I have a rollover menu with a drop down menu that I basically got from this website.We also have to make a mobile version of the page, which basically means exchanging the css style with another one(requirement for the project). On the mobile version though, I want to just have the main menu headers without the drop down or without them showing up. Right now, the mobile menu looks like the above code but without the css, so all the menu items are listed. Is there anyway to get rid of the sub-menus from showing up? Link to comment Share on other sites More sharing options...
vomitcomet Posted April 28, 2011 Author Share Posted April 28, 2011 Nevermind, I figured it out...var div = document.getElementById("");div.parentNode.removeChild(div); Link to comment Share on other sites More sharing options...
vomitcomet Posted April 29, 2011 Author Share Posted April 29, 2011 Sorry, I'm triple posting. Is there an opposite to removechild? I can make what I want disappear but I can't make them come back without refreshing the page. Link to comment Share on other sites More sharing options...
justsomeguy Posted April 29, 2011 Share Posted April 29, 2011 You can append a child. You may just want to hide and show the thing instead of removing it entirely though. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.