Re: Path question.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 28 July 2011 13:36, Nilesh Govindarajan <contact@xxxxxxxxxxxx> wrote:
> On 07/28/2011 05:43 PM, Paul Halliday wrote:
>> I have a few scripts that use "../location/file"
>>
>> Is this interpreted differently on some systems?
>>
>> Thanks.
>>
>
> I have no idea about it, but I generally use realpath() to avoid any
> such problems. Windows may have, because it uses backward slashes
> instead of forward which are used in *nix (incl mac)

For PHP on Windows, the / is fine. Obviously, if you are going to be
calling OS based tools from PHP, you'll need to realpath() or use \\
or DIRECTORY_SEPARATOR.


-- 
Richard Quadling
Twitter : EE : Zend : PHPDoc
@RQuadling : e-e.com/M_248814.html : bit.ly/9O8vFY : bit.ly/lFnVea

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux