How to create toggle effect using jQuery? I am using views to to display title,image,date,description of a specific content type. By default the first element in the views has to be shown, where else the remaining![enter image description here][1] would be hidden . When the user clicks the 2nd title the 2nd node's content has to be shown and the rest has to be hidden.
It would be great if some one can help me to achieve this.
If you prefer to handcraft you can create a template (look inside your Views template suggestions) and paste inside this code. Then using functions like views_get_view_result() you can fetch views field and use them inside it.

&lt;?php
    drupal_add_library('system', 'ui.accordion');
    drupal_add_js('jQuery(document).ready(function(){jQuery("#accordion").accordion();});', 'inline');
    ?&gt;
    &lt;div id="accordion"&gt;
    &lt;h3&gt;&lt;a href="#"&gt;Section 1&lt;/a&gt;&lt;/h3&gt;
    &lt;p&gt;Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.&lt;/p&gt;

    &lt;h3&gt;&lt;a href="#"&gt;Section 2&lt;/a&gt;&lt;/h3&gt;
    &lt;p&gt;Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.&lt;/p&gt;

    &lt;h3&gt;&lt;a href="#"&gt;Section 3&lt;/a&gt;&lt;/h3&gt;
    &lt;p&gt;Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.&lt;/p&gt;
    &lt;/div&gt;