This option will reset the home page of this site. Restoring any closed widgets or categories.

Reset

Expand and collapse toggle div using jquery

This is a very simple tutorial on how to show and hide a division tag or Expand and collapse toggle div using simple jquery.

<script src=”http://jqueryjs.googlecode.com/files/jquery-1.3.2.min.js” type=”text/javascript”></script>

<script type=”text/javascript”>

$(document).ready(function(){

$(”#butShowHideSlow”).click(function () {

$(”#divShowHideSlow”).toggle(”slow”);

});

});

</script>

<button id=”butShowHideSlow”>Click Me</button>

<div style=”width:300px;height:47px; border: solid 1px black;background-color:white;text-align:center;” id=”divShowHideSlow”>Div that hide and show slowly</div>

Check out the DEMO here
Very Simple Right :)

VN:F [1.5.7_846]
Rating: 10.0/10 (5 votes cast)
VN:F [1.5.7_846]
Rating: +1 (from 1 vote)

Related posts:

  1. Jquery Basics, How to use jquery?
  2. Load Another Webpage Content Using Simple Jquery
  3. Replacing images with time intervals using jquery
  4. Slideshow using jquery
  5. Automatic Ajax Loading Images With Prototype
  6. Disable submit button on form submit
  7. Caching of images using javascript image object

Leave a Reply

Comments (required)

Spam Protected