php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #12238 Double printing with echo and print
Submitted: 2001-07-18 18:39 UTC Modified: 2001-07-18 18:45 UTC
From: mahk at home dot com Assigned:
Status: Not a bug Package: Strings related
PHP Version: 4.0.6 OS:
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: mahk at home dot com
New email:
PHP Version: OS:

 

 [2001-07-18 18:39 UTC] mahk at home dot com
The following html/php script gives a duplicate of the last line.

<HTML>
<BODY><CENTER><B>
<P>System name:
<?php echo( system("hostname")  ); ?>
<P></B></CENTER> </BODY>
</HTML>

returns the following html output.

<HTML>
<BODY><CENTER><B>
<P>System name:
kelsey
kelsey<P></B></CENTER> </BODY>
</HTML>

I've used the standard compile:
 './configure' '--with-mysql' '--with-apxs'

System: Linux kelsey 2.2.19-6.2.1 #1 Mon Apr 9 21:59:11 EDT 2001 i486 unknown



Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2001-07-18 18:45 UTC] cynic@php.net
RTFM (Reading The Fine Manual) never killed anyone. You should try that. :)

"System() is just like the C version of the function in that it executes the given command and outputs the result. [...] Returns the last line of the command output on success, and false on failure."
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 19 14:01:30 2024 UTC