note 42413 added to function.system
| From: | vk at volkerkamp dot com | Date: | Sat, 15 May 2004 18:09:06 +0000 |
| Subject: | note 42413 added to function.system | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-69650@lists.php.net to get a copy of this message | ||
Problems with backslash: Using PHP for shell-scripting seems to require a quad-escape for
backslashes. Example: system("mount -t smbfs -o username=xxx,password=xxx,uid=xxx
\\\\\\\\SERVER\\\\drive ./mnt");
The string delived to "mount" is "\\SERVER\drive". So the PHP-parser needs a
backslash for every backslash and system() needs it again.
Hope this helps someone!
Volker
----
Manual Page -- http://www.php.net/manual/en/function.system.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+42413
Delete -- http://master.php.net/manage/user-notes.php?action=delete+42413&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+42413&report=yes
Search -- http://master.php.net/manage/user-notes.php