Odd output from system()

From: Date: Wed, 24 Jan 2001 04:35:12 +0000
Subject: Odd output from system()
Groups: php.general 
Request: Send a blank email to php-general+get-36328@lists.php.net to get a copy of this message
Hi, I'm running a PHP script that uses system() to call an expect script. This expect script uses ssh2 to log into another server, and run some commands. At the shell prompt (bash) the expect script runs exactly as I'd hope. However, when I use system() in PHP to run the script, the output on the web browser includes lines like this: ]0;root@apache: /root[root@apache /root]# I'd hope to see something like this instead of the above: [root@apache /root]# My guess is that there is something that the shell and/or expect is hiding from me, that system() is displaying instead. Is there some way of telling system() that it should look exactly like it does in a shell, or to tell the shell or expect not to generate this hidden info? Any advice would be appreciated! TIA, -- Andrew Hill "Right now, I'd happily snort gunk from the sink if it would take my brain somewhere away from here...." - JB

« previous php.general (#36328) next »