On Thu, 30 Jan 2003, Ananth Kesari wrote:

> Hi,
> 
> I am using the system function on NetWare. I find the following strange
> error:
> 
> 1. If I use single quoted strings, then I don't have any problem with
> any combination of the slash.
>         system('sys:\system\p.nlm');  // WORKS
>         system('sys:\\system\\p.nlm');        // WORKS
>         system('sys:\system\r.nlm');  // WORKS
>         system('sys:\\system\\r.nlm');        // WORKS
> 
> 2. If I use doble quoted string then it works in these cases:
>         system("sys:\system\p.nlm");  // WORKS
>         system("sys:\\system\\p.nlm");        // WORKS
>         system("sys:\\system\\r.nlm");        // WORKS
> 
> 3. If I use double quoted string and I use single slash and the nlm
> name starts with 'n' or 'r' or 't', then the system function call fails
> to load the nlm thought the nlm is present in the given location. That
> is the below does not work:
>         system("sys:\system\r.nlm");  // WORKS
> 
> This erros appears to be strange with only three letters not being
> allowed. Can anyone throw some light as to what is happening here? Could
> there be a mistake in the NetWare port?

If used in a " string, these characters have the following meaning:
\r = #13 (CR)
\n = #10 (LF)
\t = #9  (tab)

so that's the reason why it doesnt work.

Derick

-- 

-------------------------------------------------------------------------
 Derick Rethans                                 http://derickrethans.nl/ 
 PHP Magazine - PHP Magazine for Professionals       http://php-mag.net/
-------------------------------------------------------------------------


-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to