Re: [in-phpug] Help! Directory handling
On Fri, 26 Jul 2002, paul alapatt wrote:
Show some real code you are using
This should be possible using PHP alone
> Hi everyone,
> I have to develop the following for a college project
> however, since I am not much into directory and file
> handling I am not making much headway.
> Schematics :
> Everytime a students logs into the server, the program
> checks if a directory with the login name of the
> student exist under say /var/www/html/homepages/ if it
> does, it does nothing, else it creates one and copies
> the contents from an already present directory say
> /var/tools into the newly created
> /var/www/html/homepages/<studentname> The directory
> 'tools' which is being copied is a set of php scripts
> which assist the student in keeping track of the
> assignments, reports,projects etc. He/she can also
> upload some images into this newly created directory.
> However the problem I facing is :
> - is_file() helps me identify if the directory exist
> under /var/www/html/homepages/ however now to copy it
> I first need to 'chmod -R 777 homepages' so I tried
> using the following but it does not seem to work under
> safe mode of php
> - chmod()
> - system()
> - backtick operator
> - shell_exec()
> Now can anyone suggest to me how this can be done,
> exclusively in PHP and at max some shell script which
> I can call using the shell_exec or system(), I cannot
> use PERL or any other language for that matter.
> Looking forward to a prompt reply.
> Thanks in advance.
> Paul Alapatt
> Do You Yahoo!?
> Yahoo! Health - Feel better, live better
> Yahoo! Groups Sponsor
> Read Posting Guidelines at
> To unsubscribe from this group, send an email to:
> Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
PHP Applications for E-Biz: http://www.sanisoft.com
Indian PHP User Group: http://groups.yahoo.com/group/in-phpug