PHP OS (Operating System) Detection

Jan 27

Now a days with cross browser compatibility issues ranging outside of just Windows/PC as Mac’s and Linux become more user friendly and popular you get issues that aren’t necessarily the same thing cross OS’s now. Example something I do in chrome on my Windows PC works well, where on my MAC it fails. So what do I do? I spend either a lot of time making it work for both often losing functionality or I make two different versions one working for the need of each OS. How do I detect the OS? easy Ill show you in a second.
The other reason someone may want to have OS detection is cause they offer software for example. For all platforms. But to make the user experience more friendly they want to give the user the ability to download the software faster, without having to dig through a list of all operating systems for there match. This is a quick way to build a landing page based on OS as well.

No related posts.

Leave a Reply

*