...........please somebody help me with this .....
i want to display images contained in a folder (basically www dir in wamp).......
the images should be displayed on a webpage......
its like a search box.....you hav to enter the name of the folder to view its images.......
...............please help me with this............

Member Avatar for Mouche

To add images, you just use HTML:

<img src="SOURCE OF IMAGE" alt="TEXT IF IMAGE DOESN'T SHOW"/>

Is that your only problem? I can't quite understand what you are asking for.

Once again PHP.net has the answer.

I believe you were wanting to return all the files within a directory, as the person above me stated this was not very easy to understand what you were wanting to do.

$d = dir("/etc/php5")
while(false!==($temp=$d->read()))
{
   $filesinfolder[]=$temp
}

This should return an array containing all the files in that folder.

Examine more of php.net/dir for more information on directory functions and functionality

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.