php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #41311 <?=// doesnt work in PHP 5
Submitted: 2007-05-07 08:27 UTC Modified: 2007-05-07 12:43 UTC
From: khuram dot shahzad at yahoo dot com Assigned:
Status: Wont fix Package: Unknown/Other Function
PHP Version: 5.2.2 OS: Windows 2000
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 — but make sure to vote on the bug!
Your email address:
MUST BE VALID
Solve the problem:
7 + 39 = ?
Subscribe to this entry?

 
 [2007-05-07 08:27 UTC] khuram dot shahzad at yahoo dot com
Description:
------------
<?=//comments?>

the above line was working when i was using php 4.4. After updating to PHP 5.2 the same Line of code is giving Parse error 




Reproduce code:
---------------
<?=//comments?>

Expected result:
----------------
Parse error: syntax error, unexpected ';' in D:\Program Files\Apache Group\Apache2\htdocs\test.php on line 2

Actual result:
--------------
it should execute without parse error

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2007-05-07 12:43 UTC] tony2001@php.net
<?=...?> is a shortcut for "echo ...", therefor this code is definitely wrong.

 
PHP Copyright © 2001-2022 The PHP Group
All rights reserved.
Last updated: Mon Jan 24 07:03:34 2022 UTC