Jason FB wrote:
PHP General List,

Regarding my the previous post -- the script had another bug in it which I felt silly for having posted since it's so obvious at the very top (a misisng "=" sign).

However, I am still having a problem with this script practically copied and pasted from the PHP manual.

The revised script is below, the parse error I am actually seeing now after adding the = sign is as follows:

Parse error: parse error, unexpected T_ECHO in D:\Inetpub\wwwroot\imagesexotic\Fall04\admin\check_set.php on line 6


Thanks... -JFB-

<?php
// Note that !== did not exist until 4.0.0-RC2

$root_dir = "/Users/jason/Sites/";

$folder_on_server = "";

This is line 6 ^^^^. The closest echo statement is couple lines below. Please COPY and PASTE your actual code, DO NOT retype it. You can introduce errors that are not in your original code, or fix it like this time.





if ($handle = opendir($root_dir . $folder_on_server)) { print "Directory handle: $handle\n"; print "Files:\n";

     /* This is the correct way to loop over the directory. */
     while (false !== ($file = readdir($handle))) {
        echo "$file\n";
    }

     closedir($handle);
 }
?>

-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php



Reply via email to