Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact us.

Post New Thread Reply

Register GFY Rules Calendar Mark Forums Read
Go Back   GoFuckYourself.com - Adult Webmaster Forum > >
Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed.

 
Thread Tools
Old 01-11-2003, 01:08 PM   #1
psyko514
See sig. Join Epic Cash.
 
Join Date: Oct 2002
Location: Montreal, Quebec. ICQ: 214702014
Posts: 22,366
copying directories in PHP

i want to copy an entire directory and it's subdirectories with all it's files into a new, randomly-named directory

can someone point me towards a good PHP function? i've seen the rec_copy function, but it doesn't seem to work for me.

and my server won't allow me to run shell commands, so cp -r doesn't work either
psyko514 is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 01-11-2003, 01:13 PM   #2
TFCash
Confirmed User
 
Industry Role:
Join Date: Apr 2001
Posts: 1,738
What error does it give you when you try rec_copy ?? That function works fine for me, so maybe you host has shut off some php commands that are going to be needed to do what you want to achieve.


Tim
TFCash is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 01-11-2003, 01:17 PM   #3
psyko514
See sig. Join Epic Cash.
 
Join Date: Oct 2002
Location: Montreal, Quebec. ICQ: 214702014
Posts: 22,366
that's my problem... it doesn't give me any errors... it just doesn't do it!
psyko514 is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 01-11-2003, 01:25 PM   #4
psyko514
See sig. Join Epic Cash.
 
Join Date: Oct 2002
Location: Montreal, Quebec. ICQ: 214702014
Posts: 22,366
ok, i messed around a bit, and I got it to copy the directory structure, but it won't copy the files

it gives me this error:
Quote:
SAFE MODE Restriction in effect. The script whose uid is 10009 is not allowed to access /usr/local/psa/home/vhosts/xxxxxxxx.com/httpdocs/ngnd/girls/temp/gal_1 owned by uid 48 in /usr/local/psa/home/vhosts/xxxxxxxx.com/httpdocs/ngnd/girls/preview_gal.php on line 46
line 46:
PHP Code:
copy($from_path."/".$file$to_path."/".$file); 

Last edited by psyko514; 01-11-2003 at 01:29 PM..
psyko514 is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 01-11-2003, 02:45 PM   #5
psyko514
See sig. Join Epic Cash.
 
Join Date: Oct 2002
Location: Montreal, Quebec. ICQ: 214702014
Posts: 22,366
i guess i should just keep tweaking the rec_copy function?
psyko514 is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Post New Thread Reply
Go Back   GoFuckYourself.com - Adult Webmaster Forum > >

Bookmarks
Thread Tools



Advertising inquiries - marketing at gfy dot com

Contact Admin - Advertise - GFY Rules - Top

©2000-, AI Media Network Inc



Powered by vBulletin
Copyright © 2000- Jelsoft Enterprises Limited.