Jump to content

Display different text in different browsers


ProgramPotato
 Share

Recommended Posts

Hi, I know there is a way to detect browsers with javascript, and i would like to have this in my website, but what I find on the internet doesn't give me exactly what I want. I want a sentence to display only in Chrome and Safari:

Thank you for using Chrome or Safari for browsing this website. You are expiriencing this page the best it can be!
And i want every other browser to display this:
This website works best if using <a href="www.google.com/chrome">Chrome</a> or <a href="www.apple.com/safari">Safari</a>. Please consider using them.
Hope it works out!
Link to comment
Share on other sites

There is no way to detect what browser the user has. And it's the mark of a bad web developer to ask the users to use a different browser. If you can't get the page to look right in Firefox or Opera then you must have done something wrong.

Link to comment
Share on other sites

There is no way to detect what browser the user has. And it's the mark of a bad web developer to ask the users to use a different browser. If you can't get the page to look right in Firefox or Opera then you must have done something wrong.
Thanks. It's not like i have a game that only works in IE or something. I should just let it go. And there is a way, btw. Edited by ProgramPotato
Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...