php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #29459 Parser loses output of simple expression ending with an addition.
Submitted: 2004-07-30 18:14 UTC Modified: 2004-08-05 23:09 UTC
From: c dot lohl at web dot de Assigned:
Status: Not a bug Package: *Math Functions
PHP Version: 4.3.7 OS: Win2k Server
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem:
33 + 27 = ?
Subscribe to this entry?

 
 [2004-07-30 18:14 UTC] c dot lohl at web dot de
Description:
------------
The parser loses the first part of the output of an expression containig numbers and strings with a simple addition at the end.

Environment: Win2k Server (SP4) with Apache 2.0.50 and PHP 4.3.7 (installed via TSW 3.3.3), no changes in php.ini (but the paths).
Sorry if this information does not fit your needs, I'm totally new to PHP (found this problem reading a tutorial...)

Reproduce code:
---------------
<?
  echo "This doesn't work: <br>";
  $i = 16;
  $j = 26;
  echo $i."+".$j."=".$i+$j;

  echo "<br> No problem with this: <br>";
  $k = 42;
  echo $i."+".$j."=".$k;
?>

Expected result:
----------------
Output: 16+28=42

Actual result:
--------------
Output: 42

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2004-07-30 18:16 UTC] c dot lohl at web dot de
Sorry, forgot this: the problem does not occur with operators  -, *, /.
 [2004-08-05 23:09 UTC] edink@php.net
echo $i."+".$j."=".($i+$j); will work much better.

 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun Jul 21 22:01:28 2024 UTC