Jump to content

[SOLVED] function isdir()


snorky

Recommended Posts

PHP version = 4.4.9

 

Pseudo-code for what I'm trying to do:

 

if $path is not a directory
then print ""
else print $path . "<br />"

 

Actual code attempts:

 

// declare a variable
$path = $folder.'/'.$file;

 

What I've tried once the variable is set:

 

if ((isdir($path)=FALSE)

if (!isdir($path))

 

In desperation I tried to see how the test evaluates:

 

$test=var_dump(isdir($path));
echo $test;

In each case the result is:

 

Fatal error: Call to undefined function: isdir() in listall.php on line 60

 

Link to comment
https://forums.phpfreaks.com/topic/159314-solved-function-isdir/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.