Jump to content

Glob is not an array?


Hypersource

Recommended Posts

I'm not sure that a glob() supports the Hypertext Transfer Protocol (HTTP).

 

Example2, if the searchable images are outside of the current directory: 

$dir = $_SERVER['DOCUMENT_ROOT'].'/'.'path_to_image_directory';

foreach (glob($dir.'/'.'*.*') as $filename)
{
   echo "<a href=\"".$filename."\">".$filename."</a><br/>";
}

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.