jovypinoy 0 Junior Poster in Training

Hello guys, I hope someone can help me on my problem. Actually I insert a jquery funtion to pause my slideshow but it didn't work..

Thanks for the help in advance.

Here is my codes

Variables for the links and images of slideshow.

var links = new Array();
links[0] = '';
links[1] = '';
links[2] = '';

var imageUrl = new Array();
var imageTitle = new Array();
var imageCaption = new Array();

This is to call the image in my directory

for($counta=0; $counta<$count; $counta++)
    echo "imageTitle[".$counta."]=\"".$imageTitle[$counta]."\";";
    echo "imageUrl[".$counta."]=\"".$imageURI[$counta]."\";";
    echo "imageCaption[".$counta."]=\"".$imageCaption[$counta]."\";";


Slideshow codes and the dots.


jQuery(document).ready(function() {

var a=0;
    function changepicture() {
        jQuery("#slideshowpicture img").attr('src', imageUrl[a]);
        document.getElementById("changeable").href = links[a];
        jQuery(".dot"+a).attr('src', "<?php echo $templateuri; ?>/images/home/dotw.jpg");
        if( a == 0) {
            jQuery(".dot<?php echo $count-1; ?>").attr('src', "<?php echo $templateuri; ?>/images/home/dotb.jpg");
        else if( a == <?php echo $count-1; ?>) {
            b = a - 1;
            a = 0;
            jQuery(".dot"+b).attr('src', "<?php echo $templateuri; ?>/images/home/dotb.jpg");
        else {
            jQuery(".dot"+b).attr('src', "<?php echo $templateuri; ?>/images/home/dotb.jpg");
    var slideinterval = setInterval(changepicture, 4000);

This is my function to pause an slideshow. But it failed. :(

$('#slideshow').hover(function() {
    function() {
        slideinterval =  setInterval( "changepicture()", 4000 );


Few codes under this script codes.

<div id="main" class="frontpage">
	<div id="slideshow">
		<div id="slideshowtext">
			<div id="slideshowtext-wrap">
				<div id="slideshowtitle">

Thanks for the help in advance.. :)