conditional window open
I'm new to JS and PHP. I'm looking for a script to detect OS=Mac and Browser=IE which will then open a pop-up URL. I'm leaning towards PHP as not everyone has JS turned on. Reason for this script is to alert Mac IE users that it no longer supports FlashPlayer 8+ and to use a different browser. Any help would be much appreciated. Thank you.
Back to top |
|||||
This is a simple php browser detection script we do.
And this is the full featured browser detector. And if you search these web programming forums you'll find lots of posts on how to implement them. We will not, however, teach you how to program, that's your job, not ours. popups are a function of javascript and cannot be triggered by php, php is a server side scripting technology, which means it runs before the client browser receives the page html, and javascript is a client side scripting technology, which means it runs after the client browser has received the page code. With php however you can redirect the user, or display a message on the page to the user, etc. We also have a javascript browser detector, which works fine as well, and would probably be less of a learning curve for you to implement. Don't worry about the tiny handful of mac users who might have their javascript turned off, macs already constitute no more than 3% of total global computer users, and most macs out there are running up to date software, browsers, and flash stuff, so the people you are targetting are almost by definition the very people who would have n o idea that you can even turn off javascript in the first place. With no programming background I recommend you use the javascript detectors, javascript is a lot easier to implement if you have never done any programming at all, and requires no server configurations or any particularly obscure or advanced knowledge, and can be popped right into any existing page. But, again, we want to emphasize: we do not do beginner web programming tutorials, you'll have to find some other forums for that. These scripts are provided as a service, and, as the GPL says: :: Quote :: This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. Also without any implied or explicit offer of unlimited free assistance to anyone who wants it. So get to work, start studying programming, read up, buy books, check out online tutorials. None of these scripts are basic, but what you want could easily be done in a few lines of code, although detecting flash versions is not something we have ever had interest in offering as a feature to be honest, though it can be done. And it can only be done with javascript if I remember right. Back to top |
|||||
Thanks
Thanks for your help. I'll get on it.
Back to top |
|||||
All times are GMT - 8 Hours
|