ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> php-db
php-db
Re: [PHP-DB] Problem in executing linux command from PHP
by Gnanavel other posts by this author
Aug 29 2003 7:09AM messages near this date
Re: [PHP-DB] delte stmt problem with joins | RE: [PHP-DB] SELECT Part of a Field
Quoting  holmes072000@charter.net:

>  From: "Gnanavel" <gnanavel_online@[...].com>
>  
>  
>  > I have problem in executing  linux command
>  >
>  > $output=exec("ls -a");
>  > echo "<pre>$output</pre>";
>  >
>  > the above coding works, but
>  >
>  > $output=exec("cp file1 file2");
>  > echo "<pre>$output</pre>";
>  >
>  > does not works. can any one help me out of this problem
>  
>  Riddle me this... exec() returns the last line of output from the result
>  of
>  the command. What is the last line of output when you run "cp file1
>  file2"
>  from the command line?
>  
>  ---John Holmes...
>  
>  

When I was executing the "cp" command it doesn't return anything. 
But it returned the name of the last file when i executed the "ls" command

-------------------------------------------------
Sify Mail - now with Anti-virus protection powered by Trend Micro, USA.
Know more at http://mail.sify.com

Sify Power mail- a Premium Service from Sify Mail!
know more at http://mail.sify.com

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState Software Inc. All rights reserved