php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #16795 function's optional parameter
Submitted: 2002-04-24 10:23 UTC Modified: 2002-04-24 10:59 UTC
From: emailleonid at start dot com dot au Assigned:
Status: Not a bug Package: Reproducible crash
PHP Version: 4.2.0 OS: winxp
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: emailleonid at start dot com dot au
New email:
PHP Version: OS:

 

 [2002-04-24 10:23 UTC] emailleonid at start dot com dot au
when function defined in a maner
<?
 function test ($param = "$"){
   echo $param;
 }

 test();
?>

u get

Parse error: parse error in D:\InetPub\test.php on line 2

when

<?
 function test ($param = "a"){
   echo $param;
 }

 test();
?>

Everything works as planed

a

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-04-24 10:31 UTC] derick@php.net
The bug system is not the appropriate forum for asking support
questions. For a list of a range of more appropriate places to ask
for help using PHP, please visit http://www.php.net/support.php
 [2002-04-24 10:59 UTC] hholzgra@php.net
hint: try function test ($param = '$'){
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun May 05 04:01:32 2024 UTC