Reply to Trouble moving directory

Your name:

Reply:


Posted by "-k." on 10/13/05 05:11

I'm having trouble moving some directories. My script works fine on some directories but doesn't
move others. It seems to have trouble with directories with non alphanumeric charters. I'm running
Red Hat FC2. I'm trying to move the directory basically like this...

<?Php

$source_dir = '/some/dir/Dir That Won't Move/';
$dest_dir = '/some/other/dir/'

$cmd = escapeshellcmd("mv ".$source_dir." ".$dest_dir);
$result = shell_exec($cmd);

?>

Is there some way to escape the characters in the directories? For example if i put a "\" in front
of blank spaces it takes care of those (same for "'","(" etc.) but that obviously doesn't take
care of everything. I'm hoping there is something easy i'm overlooking here that will escape all
the characters.




-k.




__________________________________
Yahoo! Mail - PC Magazine Editors' Choice 2005
http://mail.yahoo.com

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация