Borwser's OS ?

S

Steve Pugh

Mel said:
how can i find out the OS the browser is running on ?

Your browser? You should know already.

Your user's browser? It's often in the User Agent string and hence in
your log files, but even if it is there then it may not be accurate.

Why do you want to know?

Steve
 
U

Uncle Pirate

Mel said:
how can i find out the OS the browser is running on ?

thanks
Wild guess? The information is in the environment but useless because
it can be changed to whatever the user wants.

And why care? HTML is not OS specific.

--
Stan McCann "Uncle Pirate" http://stanmccann.us/pirate.html
Webmaster/Computer Center Manager, NMSU at Alamogordo
Coordinator, Tularosa Basin Chapter, ABATE of NM; AMA#758681; COBB
'94 1500 Vulcan (now wrecked) :( http://motorcyclefun.org/Dcp_2068c.jpg
A zest for living must include a willingness to die. - R.A. Heinlein
 
D

Duende

While sitting in a puddle rf scribbled in the mud:
That's nasty. You know how hard it is to steal PHP code!
Richard is a smart gentleman. He doesn't need to steal the code. He knows all
about php and how to make it work for him.
 
R

rf

Duende said:
While sitting in a puddle rf scribbled in the mud:
Richard is a smart gentleman. He doesn't need to steal the code. He knows all
about php and how to make it work for him.

Ah, yes, well then when he publishes his solution we will undoubtedly
correct his intentional mistake and tell us that to get the OS one would
parse the superglobal variable entry

$_SERVER["HTTP_USER_AGENT"]

rather than use some so called PHP "command" which PHP has none of IRRC
unless RtS is confusing command with function.
 
L

Leif K-Brooks

rf said:
PHP has none of IRRC unless RtS is confusing command with function.

Well, print (and a few others) are syntax instead of functions in PHP.
You could call them commands, I guess.
 
R

rf

Leif K-Brooks said:
rf wrote:

Well, print (and a few others) are syntax instead of functions in PHP.
You could call them commands, I guess.

Go over to the PHP manual and look up "print".

To quote:

<quote>
Print() is not acually a real function (it is a language construct) ...
</quote>

PHP does not have "commands". It has language constructs and functions, just
like C[++] and family, from which it is loosely derived.

Basic (IIRC from the many years ago that I last used it) uses the term
command.

Since basic is not an extensible language like C or PHP it has a number of
constructs and many many "commands". The collection of commands is fixed.

C[++] (and PHP) has only a few constructs. That's it. The rest of the
"language" is functions, constructed from these language constructs.

This is particularly evident with C[++]. Omit the function extensions (that
is omit including any .h files and libraries) and you have quite a small
number if primatives, namely things like +, -, ++ etc. To do any real work
one *requires* the function libraries. In particular C++ does not, in its
native form, have any means of interacting with the user (eg, a UI). It does
not have a "print" construct. "Printing" must be done with library
functions and at the bottom line these are written in assembly language
(targeted to the appropriate processor), not C[++].

PHP is more generous. It includes extended language constructs such as
print. They are not, however, commands.

</pedant> :)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,581
Members
45,056
Latest member
GlycogenSupporthealth

Latest Threads

Top