|
Posted by Johnny on 02/27/06 22:16
"Martie" <martienospammin@newsguy.com> wrote in message
news:dtvhcf0h5q@drn.newsguy.com...
> In article <7naMf.2574$p43.2221@fed1read05>, Johnny says...
> >
> >
> >"David Haynes" <david.haynes2@sympatico.ca> wrote in message
> >news:PG5Mf.9897$2a4.2573@fe71.usenetserver.com...
> >> henshu wrote:
> >> > Complete n00b question yet again. Anyone know a way to make PHP pull
a
> >> > "file list" (know as dir in windows, ls in *nix, etc) for a specific
> >> > directory, and have PHP print the results onto the page?
> >> http://www.php.net/manual/en/ref.dir.php
> >> Look at the opendir, readdir and closedir functions.
> >>
> >> -david-
> >>
> >but be aware that on most servers the openbase restrictions prevent from
> >reading outside your own directories.
> >
> >
>
> Just to clarify, did you mean those functions are limited to the
directories
> inside your normal web space? I usually try to rely on the built-in PHP
> functions than using exec() type commands. Thanks!
>
>
Not sure if it's me you're asking.. but
I had trouble finding the refs as google jacks up searching for those terms
as there are underscores involved
here:
http://us3.php.net/features.safe-mode
and
http://www.php.net/security-note.php
the built in php fns won't get you outside of your base dir on most servers.
you get opnbase errors. those same servers will also most likely stop you
from using exec() to do similar as well.
Navigation:
[Reply to this message]
|