Question : Run the first php script in background - When done - run the next script ...

Hi all Experts,
I tried to execute the first php script (Generate_The_XML_File.php) in background - When it completely done - then run the next one (Slideshow.html) ...

Please help me how to solve this problem. Thank you in advance.

Method 1: (Work great if I have about 10 JPG files in a directory and "Slideshow.html" sometimes fail to load the (Slideshow.xml) because the (Generate_The_XML_File.php) still generate the (Slideshow.xml) if I have over 100 JPG files in a directory.

If I executed the (Generate_The_XML_File.php) to generate the  (Slideshow.xml) then run the "Slideshow.html", then I have no problem. (Both of these files I executed separatedly).

<?php
{
    include('Generate_The_XML_File.php');
    include('Slideshow.html');
  }
?>
-----------------------

Method 2:

<?php
{
   include('Generate_The_XML_File.php');
    sleep(5);
}
?>
<html>
<head>
<title>Slideshow</title>
</head>
<BODY>
<div align="center">

<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0" width="700" height="500">
  <param name="movie" value="Slideshow.swf" />
  <param name="quality" value="high" />
  <param name="allowFullScreen" value="false" />
  <param name="allowScriptAccess" value="always" />
  <param name="wmode" value="transparent">
  <embed src="Slideshow.swf"
         quality="high"
         type="application/x-shockwave-flash"
         WMODE="transparent"
         width="700"
         height="500"
         allowFullScreen="false"
         pluginspage="http://www.macromedia.com/go/getflashplayer"
         allowScriptAccess="always" />
</object>

</div>
</body>
</html>

Answer : Run the first php script in background - When done - run the next script ...

The problem here is that you don't have any control over a remote routing glitch other than complaining to your ISP.  They may have a peering contract dispute with one of the needed partners and as a result are routing traffic through a less-than-ideal route to reach whereever comedycentral.com is hosting.

Traceroute doesn't always work as a diagnostic tool as sites will block the response to minimize load and chances for a DoS attack. Your best overservation is that you can stream from other sites (hulu.com, cbs.com, etc) and view full shows without stutter, but when accessing comedycentral.com it fails.  Now I'm not sure of the specific content your accessing so the only other thought would be if you have a conflict with the actual player.  Try updating your flash software (http://get.adobe.com/flashplayer/) to see if that might help.

Random Solutions  
 
programming4us programming4us