[wplug] Perl System Funcion

Eric Cooper ecc at cmu.edu
Mon Sep 3 18:44:56 EDT 2007


On Mon, Sep 03, 2007 at 06:10:20PM -0400, Matthew T. Engel wrote:
>    Something like System(“cd /home/$user/$web_root && ls), does an ls on
>    /home/$user rather than /home/$user/$web_root.  The system() function
>    returns 0, I get the same thing if I try system(cd /home/$user && cd
>    $web_root && ls).
> 
>    Any suggestions much appreciated.

Are you sure that $web_root is really set to something?
Try doing:
     system("/bin/echo user = $user web_root = $web_root")
for example.

-- 
Eric Cooper             e c c @ c m u . e d u


More information about the wplug mailing list