How to make a collapsible fieldset in my theme? I want to have collapsible fieldsets in my Drupal 7 website in add content. I added this in html.tpl.php of my theme:

&lt;?php 
print $styles;
drupal_add_js('misc/form.js');
    drupal_add_js('misc/collapse.js');

?&gt;


But nothing happend to my fieldsets.
Here's a sample code of fieldset I have used:

&lt;fieldset id="fieldset-id" class="collapsible"&gt;
  &lt;legend&gt;&lt;span class="fieldset-legend"&gt;Fieldset title&lt;/span&gt;&lt;/legend&gt;
  &lt;div class="fieldset-wrapper"&gt;
  &lt;div class="fieldset-description"&gt;Fieldset description&lt;/div&gt;
     Fieldset content
  &lt;/div&gt;
&lt;/fieldset&gt;


What is the problem?
Your theme might include jQuery 1.9. With this, I observed in Drupal 7.34 that fieldsets would not work (always shown collapsed, unclickable). Also CKEditor would not load (using the ckeditor module) and there might be other JavaScript related misbehavior.

To solve this, use jQuery 1.8 instead. I recommend the module jquery_update to handle jQuery versions in Drupal.