JessiBo
02-09-2011, 04:53 AM
There is a simple solution to this, I however have not been able to execute it correctly.
I have a top level navigation (that is dynamically populated) that when clicked reveals a hidden panel. This works. The problem is when another menu item is clicked, that panel is stacked on any panels that are already open. How do I close any open panels first before opening another one.
Below is my code:
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3/jquery.min.js"></script>
<script type="text/javascript">
$(document).ready(function(){
$(".page-item-4").click(function(){
$("#slide-panel-photo").slideToggle("slow");
});
$(".page-item-6").click(function(){
$("#slide-panel-video").slideToggle("slow");
});
});
</script>
You can see the (barely there) work in progress here http://www.jessicabo.com/max01/
Any help is greatly appreciated
I have a top level navigation (that is dynamically populated) that when clicked reveals a hidden panel. This works. The problem is when another menu item is clicked, that panel is stacked on any panels that are already open. How do I close any open panels first before opening another one.
Below is my code:
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3/jquery.min.js"></script>
<script type="text/javascript">
$(document).ready(function(){
$(".page-item-4").click(function(){
$("#slide-panel-photo").slideToggle("slow");
});
$(".page-item-6").click(function(){
$("#slide-panel-video").slideToggle("slow");
});
});
</script>
You can see the (barely there) work in progress here http://www.jessicabo.com/max01/
Any help is greatly appreciated