Hi guys,
I have a jquery bit that suppose to toggle a registration form DIV when clicking the link.
The toggle works fine but the div is visible by default and I need it hidden unless the link is clicked.
anyone see why?
$(function()
{
$("#click_here").click(function(event) {
event.preventDefault();
$("#RegisterNow").slideToggle();
});
$("#RegisterNow a").click(function(event) {
event.preventDefault();
$("#RegisterNow").slideUp();
});
});
ok got it. pardon the kb server space wasted.
$(document).ready(function()
{
$(’#RegisterNow’).hide();
$("#click_here").click(function(event) {
event.preventDefault();
$("#RegisterNow").slideToggle();
});
});
Another option is to hide the div with CSS so that it’s natural state is hidden.
yeah I think that’s the way I had it on the site I used it before (took the jquery bite w/o checking the css file).