$Name
Email: $Email
Website: $Website
Comments: $Comments
Date: $Today

.:::."; /* This Line adds the '&GuestBook=' part to the front of the data that is stored in the text file. This is important because without this the Flash movie would not be able to assign the variable 'GuestBook' to the value that is located in this text file */ $New = "$Input$OldData"; // Opens and writes the file. $fp = fopen( $filename,"w"); if(!$fp) die("&GuestBook=cannot write $filename ......&"); fwrite($fp, $New, 800000); fclose( $fp ); } // ################################################################################### // ######### Formatting and Printing the Data from the Guestbook to the Flash Movie ## // Next line tells the script which Text file to open. $filename = "GuestBook.txt"; // Opens up the file declared above for reading $fp = fopen( $filename,"r"); $Data = fread($fp, 800000); fclose( $fp ); // Splits the Old data into an array anytime it finds the pattern .:::. $DataArray = split (".:::.", $Data); // Counts the Number of entries in the GuestBook $NumEntries = count($DataArray) - 1; print "&TotalEntries=$NumEntries&NumLow=$NumLow&NumHigh=$NumHigh&GuestBook="; for ($n = $NumLow; $n < $NumHigh; $n++) { print $DataArray[$n]; if (!$DataArray[$n]) { Print "

No More entries"; exit; } } ?>