|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2002-10-24 07:27 UTC] derick@php.net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Nov 28 21:00:01 2025 UTC |
It appears as if "include()" and "require()" cannot appear inside a class definition, but outside a class method. For example, the construct class A { include ('class_a_methods.php'); } returns an error (unexpected T_INCLUDE), but class A { function foo() { include ('class_a_foo_method.php'); } } works as expected. This is a slight annoyance if one wants to keep class code in manageable chunks. Please add this feature in an upcoming version!