Ratz, I was hoping I could keep all the code in the define_main_page.php so it could be changed easily.
What file did you put the script in? can I put it in the same file that loads the .js for the homepage only?
Code:
<?php
if ($this_is_home_page) { ?>
<script type="text/javascript" src="includes/rockslideshow/rokslideshow.js"></script>
<script type="text/javascript" src="includes/rockslideshow/mootools-release-1.11.js"></script>
<script type="text/javascript">
window.RokSlideshowPath = '';
var myshow;
window.addEvent('load', function(){
var imgs = [];
imgs.push({
file: 'shop_new.jpg',
title: 'New Products',
desc: 'New Products from Johns Kerusso Store.',
url: 'http://www.langeshome.com/KERUSSO/index.php?main_page=products_new'
});
imgs.push({
file: 'pray_vote.jpg',
title: 'Pray Vote Pray',
desc: 'Think About It',
url: 'http://www.langeshome.com/KERUSSO/index.php?main_page=index&cPath=6'
});
imgs.push({
file: 'running_empty.jpg',
title: 'Running on Empty',
desc: 'There is no bigger topic that the price of gas.',
url: 'http://www.langeshome.com/KERUSSO/'
});
imgs.push({
file: 'fireproof.jpg',
title: 'Fireproof - the movie',
desc: 'Never Leave Your Partner Behind, opens in theaters September 26, 2008.',
url: 'http://www.fireproofthemovie.com/'
});
myshow = new Slideshow('slideshow', {
type: 'combo',
showTitleCaption: 1,
captionHeight: 45,
width: 640,
height: 375,
pan: 20,
zoom: 30,
loadingDiv: 1,
resize: true,
duration: [2000, 9000],
transition: Fx.Transitions.Expo.easeOut,
images: imgs,
path: 'images/homepage/'
});
myshow.caps.h2.setStyles({
color: '#fff',
fontSize: '13px'
});
myshow.caps.p.setStyles({
color: '#ccc',
fontSize: '11px'
});
});
</script>
<?php
} ?>