Jump to content

Loop javascript in PHP

- - - - -

This topic has been archived. This means that you cannot reply to this topic.
1 reply to this topic

#1
socheata

socheata

    Newbie

  • Members
  • Pip
  • 3 posts
Can you fix these code for me please?
It have the problem when i change extension to PHP, it can't loop,
I want it loop all the time.


Cheer,
Socheata
<html>
<head>
    
 <link rel="stylesheet" type="text/css" href="css/layout.css" />
 <link rel="stylesheet" type="text/css" href="css/color.css" />
 <link rel="stylesheet" type="text/css" href="css/type.css" />
    
<title>Rattanasreymoa Restuarant</title>
<script laguage="JavaScript">
var delay=2000, timerID, maxCount=6,currentCount=0;
var imgNames=new Array("images/slide1.jpg","images/slide2.jpg",  "images/slide3.jpg","images/slide4.jpg","images/slide5.jpg","images/slide6.jpg");
   function imageSlideShow()
    {
   if(currentCount >maxCount) currentCount=0;
   document.myImage.src= imgNames[currentCount];
        currentCount++;
            timerID=setTimeout("imageSlideShow()", delay);
   }
</script>
</head>
<body onLoad="imageSlideShow();">
<div id="wrapper">
  <div id="header_wrapper">
       <div id="header">
     </div>
       <div id="main_nav">
       <ul class="top_menu">
          <li class="active"><a href="index1.php">Home</a></li>	
          <li><a href="location.html">Location</a></li>	
          <li><a href="our_menu.php">Our Menus</a></li>	
          <li><a href="#">Picture Menu</a></li>	
          <li><a href="#">Reviews</a></li>	
          <li><a href="#">About Us</a></li>	
          <li><a href="#">Contact Us</a></li>	
       </ul>
    </div>      
  </div>
  <div id="wrap_content">            
       <img src="" name="myImage" width="560px" align="left">
       
        <p>  Welcome to Ranttana   Sreymao restaurant
       </p>
       <p>   Our fried quail is the   best you can have in   Cambodia.</p><br />
       <p>  We also have some   wonderful seafood:   Grill LOBSTER, fried   CRAB, Soup and more. </p>
       <p>  See our <a href="our_menu.php"  style="text-decoration:none">complete   menu</a>   or Cambodian cuisine.</p>
       
  </div>
  <br class="clear-all" />
  <div id="footer">
        <div class="note">
        <p>Rattana Sreymao Restaurant <br />
         #1b Rue289 Sankhat BeoungKokI Khan Toul Kork Phnom Penh <a href="location.html">Map</a><br />
         Cell: (855)15 885 630
         </p>
      </div>
          
  </div>
</div>      
</body>
</html>

Edited by WingedPanther, 23 September 2010 - 12:48 PM.
add code tags (the # button)


#2
Orjan

Orjan

    Writes binary right handed and hex left handed

  • Moderators
  • 3,299 posts
is it the file containting this you change extension to .php, or another file? why would this need to change file? do you need to add php as well in the file, or?
__________________________________________
I study Information Systems at Karlstad University when I'm not on CodeCall