Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:9772 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 88849 invoked by uid 1010); 9 May 2004 18:06:32 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 88812 invoked from network); 9 May 2004 18:06:31 -0000 Received: from unknown (HELO smtp.dkm.cz) (62.24.64.34) by pb1.pair.com with SMTP; 9 May 2004 18:06:31 -0000 Received: (qmail 41121 invoked by uid 0); 9 May 2004 18:06:30 -0000 Received: from r3al16.mistral.cz (HELO isis.wad.cz) (213.220.229.16) by smtp.dkm.cz with SMTP; 9 May 2004 18:06:30 -0000 Received: by isis.wad.cz (Postfix, from userid 1001) id 63D462FDA01; Sun, 9 May 2004 20:06:30 +0200 (CEST) Date: Sun, 9 May 2004 20:06:30 +0200 To: internals@lists.php.net Message-ID: <20040509180630.GA74348@isis.wad.cz> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.6i Subject: system() behavior different from perl, python, ruby From: neuhauser@chello.cz (Roman Neuhauser) Could some kind soul tell me why is php's system() function different from the rest of the pack? perl -e "system('man 3 printf');" ruby -e "system('man 3 printf');" python -c "import os; os.system('man 3 printf');" php -r "system('man 3 printf');" In perl, ruby, and python, the above has the same results as typing man 3 printf, IOW the pager takes the terminal and you can browse the man page till you quit the pager. In php, the result is the man page streamed through, and the pager immediately quits. I'm observing this behavior with 4.3.6 but remember seeing this behavior in 4.0.6 or something around that time. PHP 4.3.6 (cli) (built: May 2 2004 20:16:20) Copyright (c) 1997-2004 The PHP Group Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies -- FreeBSD 4.9-RELEASE-p2 7:58PM up 6:05, 3 users, load averages: 0.04, 0.04, 0.01