|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2000-08-10 16:43 UTC] stas@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Tue Nov 04 23:00:01 2025 UTC |
<?php function x($a = "foo") { print $a; } $val = NULL; x($val); ?> This should print out "foo" but it doesnt. For my understanding this is an inconsequent behaivour. If i have <?php $a = NULL; if (isset($a)) print "ok"; ?> "ok" won't be printed. So, if there is no value set, as isset says, there should not be any value set when the value defaults to another value in the functions argument list.