echo new SplFileObject(__FILE__);
| From: | hakre | Date: | Tue, 29 Jan 2013 22:29:42 +0000 |
| Subject: | echo new SplFileObject(__FILE__); | ||
| Groups: | php.internals | ||
| Request: | Send a blank email to internals+get-65442@lists.php.net to get a copy of this message | ||
Can somebody shed some light why:
<?php
echo new SplFileObject(__FILE__);
returns the first line of the file (in that case
<?php)?
SplFileInfo has the path and SplFileObject extends from it but it will return the current line. I do
not really understand why and I tend to report this as a bug but I'm not sure.
--hakre