#37030 [Opn->Bgs]: No return value from functions where code is included/required
ID: 37030
Updated by: tony2001@php.net
Reported By: stevenmoss at gmail dot com
-Status: Open
+Status: Bogus
Bug Type: Scripting Engine problem
Operating System: Ubuntu 6.06
PHP Version: 5.1.2
New Comment:
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
Previous Comments:
------------------------------------------------------------------------
[2006-04-10 13:10:01] stevenmoss at gmail dot com
Description:
------------
This bug was first reported (coincidentally) exactly one year ago as
bug #32657 in Version 5.0.4, it was deemed bogus. I believe that
judgement was in error.
Reproduce code:
---------------
"Test.php"
<?php
Class TestObject {
function ReturnTest() {
require("ReturnTest.php");
}
}
$oTest = New TestObject();
Echo $oTest->ReturnTest();
?>
"ReturnTest.php"
<?php
return "Test";
?>
Expected result:
----------------
"Test" should be output
Actual result:
--------------
No output
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=37030&edit=1
Thread (5 messages)