|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2004-09-23 03:30 UTC] curt@php.net
[2020-02-07 06:11 UTC] phpdocbot@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Wed Nov 19 20:00:01 2025 UTC |
Description: ------------ In manual I see: Object interfaces allow you to create code which specifies which methods and *variables* a class must implement... But when I try to specifie a variable in my interface, I get next error: Fatal error: Interfaces may not include member variables in blah-blah-blah/script.php on line 25 Reproduce code: --------------- interface Test { public $var; } Expected result: ---------------- Fatal error: Interfaces may not include member variables in blah-blah-blah/script.php on line 25