Ctac Posted March 25, 2004 Report Share Posted March 25, 2004 Есть потребность: отображать рисунки в соответствии с браузером. Подскажите как определить какой браузер использует посетите Link to comment Share on other sites More sharing options...
Shurr Posted March 25, 2004 Report Share Posted March 25, 2004 if(navigator.appName.indexOf("Netscape")!=-1) - Netscape else if(navigator.appName.indexOf("Explorer")!=-1) - IE Link to comment Share on other sites More sharing options...
PaulGor Posted March 26, 2004 Report Share Posted March 26, 2004 Опера часто себя как "ИЕ" объявляет, поэтому у меня вот так: var Netscape, MSIE, Opera; Netscape = navigator.appName == "Netscape"; MSIE = navigator.appName == "Microsoft Internet Explorer"; Opera = navigator.userAgent.indexOf("Opera") > -1; Link to comment Share on other sites More sharing options...
man2D Posted March 30, 2004 Report Share Posted March 30, 2004 В пхп есть так называемые "переменные окружения". Возвращает тип браузера, ip-адрес и ещё много чего интересного. С помощью условного оператора можно сделать, чтобы контент паги был динамичным и зависел от браузера. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now