473,327 Members | 2,055 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,327 software developers and data experts.

operating system

How can I determine the operating system of the server that's running my
script?
Jul 17 '05 #1
5 2365


Bert Melis wrote:
How can I determine the operating system of the server that's running my
script?


Look at $_SERVER['HTTP_USER_AGENT']

<http://www.php.net/reserved.variables>

Ken

Jul 17 '05 #2
No clean, definitive way to do it IFAIK.

You can check $_SERVER['SERVER_SOFTWARE'] to see what web server is
used. Often the name of the platform is included in the string.

OS-specific info is often exposed as environment variables, so take a
look in $_ENV.

Jul 17 '05 #3
he said the SERVER.

there isn't a variable or function that gives the exact OS of the
server, but $_SERVER['SERVER_SOFTWARE'] should give u a good idea.

Jul 17 '05 #4
Bert Melis <bert.melis@offsite_remove_this_.be> wrote:
How can I determine the operating system of the server that's running my
script?


Second define on:
http://www.php.net/manual/en/reserved.constants.php

Jul 17 '05 #5
On Tue, 05 Jul 2005 17:56:42 +0200, Bert Melis wrote:
How can I determine the operating system of the server that's running my
script?


<?
$myos=PHP_OS;
print "$myos\n";
?>

--
http://www.mgogala.com

Jul 17 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

32
by: David Brown | last post by:
Hello. I recently came across a free operating system called Unununium (or something like that) and it was developed in Python and Assembly. Now, I have been looking for a way to make an...
27
by: Kevin A | last post by:
Hi, Is there a way to determine the name and version of the operating system in a portable way? (for Solaris/Linux) Thanks, Kevin
10
by: Vavel | last post by:
Hi all! I want to insert the record into the table by using an application program that includes the following statements: EXEC SQL BEGIN DECLARE SECTION; long hvInt_Stor; long hvExt_Stor;...
2
by: seash | last post by:
H iam developing my windows form application(ide:visual studio.net 2003, visual c#) on windows 2000 professional operating system , but when i run the exe on Xp operating system, the screen ...
1
by: viper7 | last post by:
Can I run the c++ compiler on the operating system that I have.. Windows nt 4 ser.pack 6a.. I understan that the compiled programs will run on my system.. I need to know if anyone is using the...
1
by: evan | last post by:
Hi anyone, I have to distribute a VB.NET project that requires the installation of Jet 4.0. As the installation files of Jet are operating system specific, during deployment I need to run the...
3
by: PythonUsr | last post by:
Although I know for a fact that an Operating System can be written in Python, I need to ask some questions to the more advanced users of Python. Uuu and Cleese are two operating systems that...
1
by: newstips6706 | last post by:
The Operating System of Organic Machines Building your own "KERNEL". --------------------------------------------------------------------------------
1
by: jdresow | last post by:
I installed MySQL on a windows server 2003, in an acxtive directory domain and I get error 32 which is a sharing error. I do not understand this and I am also adding the first several lines of my...
6
by: pavanip | last post by:
Hi, I have developed one windows application using vb.net. I have setup that application on windows operating system its working fine on windows os. Now I am trying to do that exe run on Mac...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.