freelance84 Posted August 30, 2010 Share Posted August 30, 2010 http://www.phpfreaks.com/forums/index.php/topic,308549.0.html The above link is a problem relating to CSS. The way route i've choosen thanks to haku is to determine the users browser then let php give one css or another. What is the best way to determine the users browser. At the moment i can only find a problem with css fixed in ie6 and below. Therefore i only really need to find if the user is running on ie6. I've come accross the http://php.net/manual/en/function.get-browser.php but requires http://browsers.garykeith.com/downloads.asp. Is there a simpler way? Quote Link to comment https://forums.phpfreaks.com/topic/212096-most-efficient-browser-determination-method/ Share on other sites More sharing options...
RussellReal Posted August 30, 2010 Share Posted August 30, 2010 you should never need to do this.. unless you're delivering browser dependant plugins or operating system specific.. the popup can work solely on position: absolute; across every browser.. you just need to declare the popup in html source OUTSIDE of your content div.. for example.. <body> <div>LALALALA</div> <div id="popup"> </div> </body> then code it the wya you normally would however, I also suggest you make #popup width: 100%; and inside have a popupContainer.. that is X wide or whatever.. position: relative; margin: auto; that will position it in the center aslong as #popup has text-align: center; specified good luck Quote Link to comment https://forums.phpfreaks.com/topic/212096-most-efficient-browser-determination-method/#findComment-1105326 Share on other sites More sharing options...
JasonLewis Posted August 30, 2010 Share Posted August 30, 2010 And besides, I don't think haku was referring to you using PHP to determine the users browser when referring to conditional statements, but Conditional Comments. If you really need to load a separate stylesheet for IE: <!--[if IE 6]> Load another stylesheet for IE <![endif]--> More information can be found here. Quote Link to comment https://forums.phpfreaks.com/topic/212096-most-efficient-browser-determination-method/#findComment-1105411 Share on other sites More sharing options...
freelance84 Posted August 31, 2010 Author Share Posted August 31, 2010 ahhh, well, thats slightly embarrasing. I never knew about conditional comments like that lol! Thanks. Quote Link to comment https://forums.phpfreaks.com/topic/212096-most-efficient-browser-determination-method/#findComment-1105526 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.