title: If body class equals X then do something?
body: <p>I have this code running from an external script for an image slider for every page on a site. </p>
  
  <pre><code>$(document).ready(function() {
    $("#slideshow").show();
    $('#slider1').anythingSlider({
      buildNavigation: false,
      delay: 8000
      })
  </code></pre>
  
  <p>On one of the pages I don't want the image slider to rotate automatically so I need to add an extra variable. I've put a class on the body of the page and want to do something along the lines of...</p>
  
  <p><strong>If the body has a class of 'partnerCharitiesDetail' then run this script instead of the generic one</strong> </p>
  
  <p>This is what I have tried below (without success). I have 2 questions really, </p>
  
  <p>1) What happens in jQuery when there are 2 identical scripts running (like this example), will it overwrite the older one with the newer one?</p>
  
  <p>2) Where am I going wrong?! Is my approach the best way to do it?</p>
  
  <pre><code>$(document).ready(function() {
   $("#slideshow").show();
    $('#slider1').anythingSlider({
      buildNavigation: false,
      delay: 8000
    })
  
    if ($('body.partnerCharitiesDetail').length &gt; 0){
    $('#slider1').anythingSlider({
    buildNavigation: false,
    delay: 8000,
    startStopped: false
   }) 
  }
  </code></pre>
  
  <p>Thanks!</p>