php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #37603 __FILE__ dereferences symlinks
Submitted: 2006-05-26 14:55 UTC Modified: 2006-05-26 15:02 UTC
From: dmitry at rsl dot ru Assigned:
Status: Not a bug Package: Directory function related
PHP Version: 4.4.2 OS: Linux
Private report: No CVE-ID:
 [2006-05-26 14:55 UTC] dmitry at rsl dot ru
Description:
------------
I have test2.php file, which is symlink to test.php
test.php is:
<?=__FILE__; ?>

No matter which file is executed, the result is the same
[dvereschaka@ns test1]$ php test.php ; php test2.php
/home/dvereschaka/test/test1/test.php
/home/dvereschaka/test/test1/test.php

Reproduce code:
---------------
<?=__FILE__; ?>



Expected result:
----------------
/home/dvereschaka/test/test1/test.php
/home/dvereschaka/test/test1/test2.php


Actual result:
--------------
/home/dvereschaka/test/test1/test.php
/home/dvereschaka/test/test1/test.php

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2006-05-26 15:02 UTC] derick@php.net
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

.
 
PHP Copyright © 2001-2014 The PHP Group
All rights reserved.
Last updated: Sun Apr 20 10:02:06 2014 UTC