Thanks Eric.

This constant PHP_OS doesn't give the OS version number. I don't need that
at this moment, but it would be useful to distinguish. OS funtionality can
change as much from one version to the next as from one platform to another.
How do I go about submitting this as a feature suggestions for PHP?

BTW, while it is true that PHP_OS appears in the manual, it's meaning is not
defined anywhere. The following man pages:
/manual/en/reserved.constants.core.php
/manual/en/reserved.constants.standard.php
list a number of predefined constants, but don't say what they mean, nor
what if any function they are associated with. Isn't that kind of important?
A hyperlink from these lists of constants to any associated functions would
be quite useful. For example, take a guess at "EXTR_REF". I'm sure PHP
experts know the answer, but what about those of us learning the language.
For the latter I'd like to submit a documentation suggestion. I'll try
forwarding this message to [EMAIL PROTECTED]

John

----- Original Message -----
From: "Eric Gach" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Cc: "'John M. Calvert'" <[EMAIL PROTECTED]>
Sent: Saturday, March 22, 2003 6:57 PM
Subject: RE: [PHP-WIN] determine host platform - win32 / *nix


> There's a few examples of this in the manual somewhere... but here's
> some basic code for it:
>
> if (strtoupper(substr(PHP_OS, 0,3) == 'WIN'))
>     dl('module.dll');
> else
>     dl('module.so');
>
> Hope that helps.
>
> ~ Eric Gach
> EvilWalrus.com Co-Administrator
>
> -----Original Message-----
> From: John M. Calvert [mailto:[EMAIL PROTECTED]
> Sent: Saturday, March 22, 2003 8:03 AM
> To: [EMAIL PROTECTED]
> Subject: [PHP-WIN] determine host platform - win32 / *nix
>
> Hello, how do I determine from code the host platform running PHP? For
> example, php.dl() requires a different module name under Win32 and *nix
> so
> for more portable code I would like to write something like:
> if (php_platform() == WIN32)
>     dl('module.dll');
> else
>     dl('module.so');
>
> Does this exist?
>
> John M. Calvert, M.Sc., MCSD
>
> 1310521 Ontario Inc.
> 49 Belmont Ave.
> Ottawa ON K1S 0V2
> (613) 730-9851
> http://members.rogers.com/john-m-calvert/

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

Reply via email to