PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
Moderator: General Moderators
Dale
Forum Contributor
Posts: 466 Joined: Fri Jun 21, 2002 5:57 pm
Location: Atherstone, Warks
Post
by Dale » Fri Feb 04, 2005 8:35 am
Can
move whole folders? With all its contents to? AND keep an original folder still where it was?
feyd
Neighborhood Spidermoddy
Posts: 31559 Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA
Post
by feyd » Fri Feb 04, 2005 8:39 am
I seriously doubt it.. why not try it?
Dale
Forum Contributor
Posts: 466 Joined: Fri Jun 21, 2002 5:57 pm
Location: Atherstone, Warks
Post
by Dale » Fri Feb 04, 2005 8:47 am
I tried
Code: Select all
<?php
copy ("users", "dalehay") or die ("Could not move");
?> and placed it in the main directory.
I went to
...co.uk/tester.php and it just says
Warning: copy(dalehay): failed to open stream: Is a directory in /home/dframe/public_html/tester.php on line 2
Could not move
So i take it there isnt a way...
feyd
Neighborhood Spidermoddy
Posts: 31559 Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA
Post
by feyd » Fri Feb 04, 2005 8:50 am
why not create your own?
Dale
Forum Contributor
Posts: 466 Joined: Fri Jun 21, 2002 5:57 pm
Location: Atherstone, Warks
Post
by Dale » Fri Feb 04, 2005 8:54 am
feyd wrote: why not create your own?
eh? What do you mean?
feyd
Neighborhood Spidermoddy
Posts: 31559 Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA
Post
by feyd » Fri Feb 04, 2005 8:55 am
create your own function to copy the contents of one folder to another.
Dale
Forum Contributor
Posts: 466 Joined: Fri Jun 21, 2002 5:57 pm
Location: Atherstone, Warks
Post
by Dale » Fri Feb 04, 2005 8:56 am
feyd wrote: create your own function to copy the contents of one folder to another.
Ignore what my CT says, but im still a n00b. But i'll have a snoop around on the internet and see if anyone has done it themseleves...
feyd
Neighborhood Spidermoddy
Posts: 31559 Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA
Post
by feyd » Fri Feb 04, 2005 8:59 am
it's not hard... opendir() / glob() with some copy() calls...
MrKnight
Forum Newbie
Posts: 22 Joined: Fri Jan 28, 2005 8:54 am
Location: Another Planet
Post
by MrKnight » Sat Feb 05, 2005 5:54 am