- This topic is empty.
Viewing 5 posts - 1 through 5 (of 5 total)
Viewing 5 posts - 1 through 5 (of 5 total)
- The forum ‘JavaScript’ is closed to new topics and replies.
The forums ran from 2008-2020 and are now closed and viewable here as an archive.
Home › Forums › JavaScript › Header pull down
Hello,
Okay I am beginning some client work (http://dl.dropbox.com/u/133074/Medical%20Futures/index.html) and I would like for the header to drop down when a navigation link is clicked on – so the page is filled with purple and the content for that specific page appears.
I assume this is possible? How difficult would this be to achieve?
Thanks,
Edit: I’d like the pages to look something like this: http://dl.dropbox.com/u/133074/Medical%20Futures/about.html – so the purple bar drops down when the page is clicked (without the browser refreshing) and this appears
#dropdown {
display: none;
}
$('#link').click(function(){
$('#dropdown').html('whatever you want to do');
$('#dropdown').slideDown();
});
Something like that?
I wonder if this codepen might help you…http://codepen.io/mmoustafa/pen/lBwhv
Just have the content inside the hidden div, I’m not sure what you’re looking for.
I don’t think you would be able to do that without something in PHP or the like. Separate pages = new HTTP request = refresh, if I’m not mistaken.