php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #37921 Feature?
Submitted: 2006-06-27 02:59 UTC Modified: 2006-06-27 05:19 UTC
From: justanotheruser2006 at yahoo dot com Assigned:
Status: Not a bug Package: Feature/Change Request
PHP Version: 5.1.5CVS OS: winxp
Private report: No CVE-ID: None
 [2006-06-27 02:59 UTC] justanotheruser2006 at yahoo dot com
Description:
------------
This is not a bug, but a sugestion. The codes output was not what was expected... When adding a value to a string that has a value in the front, should the value just increase in the front of the string and keep the remainder of the string in tact?

Reproduce code:
---------------
<?
$a = 98;
$a += 3;
echo "<br>A = $a";
$a .= " Test";
echo "<br>String A = $a";
$a += 3;
echo "<br>Test add 3 to string A = $a";
?>

Expected result:
----------------
A = 101
String A = 101 Test
Test add 3 to string A = 104 Test

Actual result:
--------------
A = 101
String A = 101 Test
Test add 3 to string A = 104

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2006-06-27 05:19 UTC] johannes@php.net
Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php

These are our casting rules which people rely on.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 19 13:01:30 2024 UTC