note 82978 added to function.getcwd

From: Date: Mon, 05 May 2008 02:44:39 +0000
Subject: note 82978 added to function.getcwd
Groups: php.notes 
Request: Send a blank email to php-notes+get-139061@lists.php.net to get a copy of this message
If you try to use getcwd() in a directory that is a symbolic link, getcwd() gives you the target of that link (similarly when parent etc. is symbolic link). There might be a better solution, but this worked for me (linux): <? php $cwd = exec('pwd'); ?> ---- Server IP: 64.71.164.2 Probable Submitter: 128.138.44.52 ---- Manual Page -- http://www.php.net/manual/en/function.getcwd.php Edit -- https://master.php.net/note/edit/82978 Del: integrated -- https://master.php.net/note/delete/82978/integrated Del: useless -- https://master.php.net/note/delete/82978/useless Del: bad code -- https://master.php.net/note/delete/82978/bad+code Del: spam -- https://master.php.net/note/delete/82978/spam Del: non-english -- https://master.php.net/note/delete/82978/non-english Del: in docs -- https://master.php.net/note/delete/82978/in+docs Del: other reasons-- https://master.php.net/note/delete/82978 Reject -- https://master.php.net/note/reject/82978 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#139061) next »