0

The following is in TestPage1.html

   <p class ="User"> 
   <a name="H1"></a>HEADING1</p>

   <div class="description" style="display:none">

--CONTENT OF THE PANEL---

   </div>

   <p class ="User">
   <a name="H2"></a>HEADING2 </p>

   <div class="description" style="display:none">

   --CONTENT OF THE PANEL---

    </div>

When the user clicks on Heading1 or Heading2, the content collapses/expands.

The following content is in another page (Testpage2.html). So when I click on the link, it is supposed to open the content in HEADING1.

    <a href="NAME OF PAGE.HTML#H1">LINK</a>

Here is the JQUERY:

    $(document).ready(function() { 
    $(".description").hide();   

    $(".User").click(function()  {    
    $(this).next(".description").slideToggle(500);  });  

    $(".User").click(function(event){ 
    window.location.hash=this.hash; 
    }); 

   });
    </script>

Any help is appreciated.

0 Answers0