PHP if else statement to load a static image or a javascript

I’m trying to make a page load static images on certain pages based on the URL in evil wordpress. The is_page does not work apparently… I am a complete and utter newb.

This is the code:

<script type="text/javascript" src="/wordpress/wp-content/fadeslideshow.js"></script>

<div id="breadcrumbs2">
      <?php if (is_page('5')) { ?>
      <img src="/images/heada.jpg">
      <? } else { ?>
      <script type="text/javascript">
		var mygallery=new fadeSlideShow({
			wrapperid: "breadcrumbs2",
			dimensions: [960, 334],
			imagearray: [
				["/images/heada.jpg", "/wordpress/?page_id=46", "", ""],
				["/images/headb.jpg", "/wordpress/?page_id=36", "", ""],
				["/images/headc.jpg", "/wordpress/?page_id=39", "", ""],
                                ["/images/headd.jpg", "/wordpress/?page_id=37", "", ""],
				["/images/heade.jpg", "/wordpress/?page_id=48", "", ""],
				["/images/headf.jpg", "/wordpress/?page_id=50", "", ""],
				["/images/headg.jpg", "/wordpress/?page_id=105", "", ""],
                                ["/images/headh.jpg", "/wordpress/?page_id=109", "", ""],
				["/images/headi.jpg", "/wordpress/?page_id=114", "", ""]
			],
			displaymode: {type:'auto', pause:5000, cycles:0, wraparound:false},
			persist: true,
			fadeduration: 1000,
			descreveal: "none",
			togglerid: ""
		})
      </script>
      <? }
?>
</div>
  

What is is_page() supposed to do?

Sponsor our Newsletter | Privacy Policy | Terms of Service