|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[1998-04-27 09:43 UTC] rasmus
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Nov 07 07:00:02 2025 UTC |
In PHP V2.0b12 there is a problem with calling functions from elseif-statements. e.g.: --------------------------------------- <HTML> <HEAD> <TITLE>skdjh</TITLE> </HEAD> <BODY> <? Function func $par ( $r_val = 1; return $r_val; ); if (0) { echo ("men"); } elseif (func ("par")) { echo ("Bingo"); } else { echo ("Default"); } echo ("<BR>r_val=" + func ("par") + "."); > </BODY> </HTML> ---------------------------------- In this example the elseif()-block is not executed although the function should return 1. If you change "$r_value=1;return $r_value;" to "return 1;" the elseif-block is executed. The only chance is to use not elseif but if.