The Web Design Group

... Making the Web accessible to all.

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> Toggle Between Firefox and IE
MMANOR
post Jan 11 2007, 01:24 PM
Post #1





Group: Members
Posts: 1
Joined: 11-January 07
Member No.: 1,527



Good Afternoon,

I understand that many scripts that work for IE may not work for Firefox and vice versa. Is there a script that can determine with internet provider a person is using to view my site and tailor the scripts to that provider? For example, currently my website is tailored strictly to IE, but I want to and need to expand to Firefox. What can be done to have the website function normally for both internet providers?

Please help wacko.gif
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Peter1968
post Jan 11 2007, 01:38 PM
Post #2


Serious Coder
*****

Group: Members
Posts: 448
Joined: 23-September 06
Member No.: 213



What are you using that's IE only?
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Christian J
post Jan 11 2007, 02:12 PM
Post #3


.
********

Group: WDG Moderators
Posts: 9,630
Joined: 10-August 06
Member No.: 7



QUOTE(MMANOR @ Jan 11 2007, 07:24 PM) *

Is there a script that can determine with internet provider a person is using to view my site and tailor the scripts to that provider?

It's also important that the site is usable if javascript is not supported at all, e.g. search engines normally ignore javascript.

Otherwise IE supports "conditional comments", that allows you to hide content (including <script> elements) for non-IE browsers: http://www.javascriptkit.com/howto/cc2.shtml there's also an equivalent for javascript code, but I've never tried it: http://www.javascriptkit.com/javatutors/co...alcompile.shtml

Other ways to try to identify browsers are unreliable: http://www.quirksmode.org/js/support.html

QUOTE
For example, currently my website is tailored strictly to IE, but I want to and need to expand to Firefox.

There's also the popular Mac browser Safari to consider.

If you begin writing a script only for IE it will be much harder to adapt it to other browsers. I think the most practical approach is to try to make a script work in as many browsers as possible from the beginning, preferably using ingredients recommended by W3C. Only use conditional comments in the rare cases when you must use proprietary code to make it work in IE.





User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Darin McGrew
post Jan 11 2007, 03:52 PM
Post #4


WDG Member
********

Group: Root Admin
Posts: 8,365
Joined: 4-August 06
From: Mountain View, CA
Member No.: 3



There are a lot of browsers besides MSIE and Firefox.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



- Lo-Fi Version Time is now: 29th March 2024 - 06:20 AM