Trying to change a div containg a slider dynamically
<p>I am using the slides plugin which can be found on here <a href="http://slidesjs.com/" rel="nofollow">http://slidesjs.com/</a>. I tested the plug in and it works. I have tried to set it up in a jquery function where if a menu is clicked on the div changes and the images of the slider change, The div has changed but the slider becomes static.</p>

<p>HTML Code</p>

<pre><code>&lt;script&gt;
$(function(){
$('#slides').slides({
preload: true,
play: 9500,
pause: 3500,
hoverPause: true,
pagination: false           
});

});
&lt;/script&gt;





&lt;div class="auto-style1"&gt;
&lt;div&gt;
&lt;a href="menu1.html" class="menuLink"&gt;Hotels&lt;/a&gt;
&lt;ul class="menu" id="menu1"&gt;
&lt;li class="hotel" hotel="ogudu" id="DGH"&gt;&lt;a href="#" &gt;DATANOMICS GUEST HOUSE,OGUDU&lt;/a&gt; &lt;/li&gt;
&lt;li hotel=""&gt;&lt;a href="#" &gt;DATANOMICS HOTEL, SHOMULU&lt;/a&gt;&lt;/li&gt;
&lt;li class="hotel" hotel="akure"&gt;&lt;a href="#" &gt;PARLIAMENT HOTEL AKURE&lt;/a&gt;&lt;/li&gt;
&lt;li class="hotel" hotel="ishua"&gt;&lt;a href="#" &gt;ISHUA HOTEL, ISHUA&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a href="index.php"&gt;Back to Main Menu&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;       
&lt;/div&gt;
&lt;/div&gt;
&lt;div class="detail_container" id="detail_container"&gt;
&lt;div class="hotel_details"&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class="hotel_details_container"&gt;
&lt;div class="hotel_details" id="ogudu"&gt;
&lt;div id="slides"&gt;
&lt;div class="slides_container"&gt;
&lt;a  target="_blank"&gt;&lt;img image1 width="675" height="375" alt="Slide 1"&gt;&lt;/a&gt;
&lt;a target="_blank"&gt;&lt;img image2 width="675" height="375" alt="Slide 2"&gt;&lt;/a&gt;
&lt;a target="_blank"&gt;&lt;img image3 width="675" height="375" alt="Slide 3"&gt;&lt;/a&gt;
&lt;a target="_blank"&gt;&lt;img image4 height="375" alt="Slide 4"&gt;&lt;/a&gt;
&lt;a target="_blank"&gt;&lt;img image5 width="675" height="375" alt="Slide 5"&gt;&lt;/a&gt;
&lt;a target="_blank"&gt;&lt;img image6 width="675" height="375" alt="Slide 6"&gt;&lt;/a&gt;
&lt;a target="_blank"&gt;&lt;img image7 width="675" height="375" alt="Slide 7"&gt;&lt;/a&gt;
&lt;/div&gt;
&lt;/div&gt;&lt;!--end of slides container--&gt;
&lt;div class="detail_containerinfo"&gt;
&lt;h2&gt;Datanomics Guest House&lt;/h2&gt;
&lt;p&gt;Datanomics Guest House is one of the loveliest luxury hotels on the Lagos Mainland, an authentic Art Nouveau palace that offers a warm inviting welcome and the delights of a true 4-star vacation. &lt;/p&gt;
&lt;br /&gt;
&lt;p&gt;
Datanomics Guest House 
&lt;/p&gt;
&lt;br /&gt;
&lt;p&gt;Discover a world of temptations in what we call the D Vacation… experience the pleasures of a holiday with the unique atmosphere and flavours you will only find here at Datanomics.&lt;/p&gt;


&lt;/div&gt;
&lt;div class="clear_both"&gt;
&lt;/div&gt;
&lt;/div&gt;
</code></pre>

<p>JQuery</p>

<pre><code>$('#DGH').click(function()
{
$('#DGH').removeClass('selected');
$(this).addClass('selected');
var hotel = '.hotel_details#' + $(this).attr('hotel');      
var htmlCode =$(hotel).html();
$('div.#detail_container').fadeOut(500,function(){
$('div.#detail_container').html(htmlCode);
$('div.#detail_container').fadeIn(500);     
});     
});
</code></pre>
