View Full Version : How do you go about getting your site to work in IE?
fly my pretties
15th of July 2009 (Wed), 08:53
Are there any good coders on this site? I could really use some advice..
I have spent the last four days redesigning my site from the ground up. I was using Indexhibit before, but stopped using it because-guess what-it didn't work properly in IE!
Now I've taken the code from Galleria and used that as the basis for my entire site. But guess what, it doesn't work in IE!
Here is my site:
www.john-godwin.co.uk
Works fine in firefox, like you'd expect, but for some reason, the front page won't work in IE, though I'm pretty sure the rest of the site works.
For instance:
www.john-godwin.co.uk/club.htm loads fine in IE and I can navigate the rest of the galleries just fine.
Does anyone have any tips they can offer me to make this site work?
tracknut
15th of July 2009 (Wed), 10:39
The best way to deal with IE is to start with a fully validated site, since IE is more picky than FireFox. If you get a doctype wrong (which you have), or leave a doctype out completely, then IE is far more likely to get the page displayed wrong.
I'm using IE8, and frankly don't see the issue you're talking about on the home page. You may be checking on a different version of IE, though. Looking at the validation (http://validator.w3.org/check?verbose=1&uri=http%3A%2F%2Fwww.john-godwin.co.uk%2Findex.htm%23img%2Ftest.jpg) I'm seeing that your doctype is screwed up, just on the home page. I'd start there...
Dave
Faolan
15th of July 2009 (Wed), 12:25
Create a separate style sheet for the version(s) that are having problems and then flag it using Conditional Statements:
Microsoft (http://msdn.microsoft.com/en-us/library/ms537512(VS.85).aspx)
Also the CSS in your site should come after the Meta-Tags, but you'll probably have to move it to a external sheet anyway.
I personally design in Opera and then work on other browsers. A good tip to try and figure out what's causing issues is to use the !important tag to suspect problem declarations to fault find and over-ride conflicting declarations. It's also advisable to add CSS bit by bit to help avoid any potential conflicts. So you may need to comment out sections of your CSS.
fly my pretties
15th of July 2009 (Wed), 16:17
My main problem is that I haven't got a bloody clue what I'm doing. Thanks for the replies guys, it gives me a base to work on a solution. Much appreciated.
tracknut, would you mind giving me some further info on the doctype I've got wrong?
tracknut
15th of July 2009 (Wed), 17:01
Your home page start off with:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/loose.dtd">
<html>
<head>
...
whereas your gallery page starts off like this:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
...
I realize this is all Greek, but bear with me just a sec. There are a couple issues here. The First doctype is for an HTML language page, and the second doctype is for an XHTML language page. Nothing inherently wrong with that, but most folks pick one or the other and stick with it. The languages are slightly different, and you've managed to code the two pages in different languages. So I'm not going to suggest you change now, but "pick one (I recommend HTML Strict, personally) and stick with it" is probably a better bet going down the road.
Then the actual issue with the doctype on the home page (I think this is also an issue on your Contacts page) is that you've got the syntax of that line wrong. It should be:
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
That doctype is HTML "loose" (meaning "give me a break on being picky about my syntax"), as opposed to "strict" (meaning "make me follow all the rules") which would be:
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">
So the easiest step to fix your doctype problem is to pick the "loose" doctype above and replace your existing one on the home page. I don't know if that will imact the bug you're seeing or not...
What version of IE are you using that shows the problem?
Dave
Hikin Mike
15th of July 2009 (Wed), 19:03
What version of IE are you using that shows the problem?
Dave
I'm going to guess IE6? :lol:
I checked your page using IE7 and I see your text is floating in the middle. Using FF3, Opera and Chrome it looks fine.
fly my pretties
16th of July 2009 (Thu), 06:25
Tracknut, thanks for taking the time to help me, I really appreciate it. Turns out I'd forgotten to close a tag.
DOH!
Thanks again :)
arnie12
16th of July 2009 (Thu), 07:11
I would suggest you forget about IE (especially the unsupported IE6) and code for standards. Make sure that validators don't find an issue and let IE6 users take care of themselves.
fly my pretties
16th of July 2009 (Thu), 09:00
No offense, but that is pretty shortsighted. I don't want to exclude an entire group of people based purely on their browser preference. That is a terrible business move.
What amounts to a small amount of effort on my part results in twice the amount of people being able to view my website. I like to stick two fingers up to Microsoft as much as the next man, but not at the cost of potential business.
Hikin Mike
16th of July 2009 (Thu), 15:50
Tracknut, thanks for taking the time to help me, I really appreciate it. Turns out I'd forgotten to close a tag.
DOH!
Thanks again :)
I wish I had a dollar for every time I forgot to close a <div>!!! :oops:
Todd Lambert
16th of July 2009 (Thu), 16:00
No offense, but that is pretty shortsighted. I don't want to exclude an entire group of people based purely on their browser preference. That is a terrible business move.
What amounts to a small amount of effort on my part results in twice the amount of people being able to view my website. I like to stick two fingers up to Microsoft as much as the next man, but not at the cost of potential business.
Very very well said.
I hate IE 6 as much or more than most people... I've been dealing with it on a daily basis for years. (I'm a web dev by trade)
The space you're seeing is a weird width set on the UL tag on the front page.
Try going here: http://westciv.com/xray/
Drag that bookmarklet to your bookmark bar... this will allow you to quickly click on items and see their padding, box model, widths, etc.. It is very useful to quickly look at how a site is built. (I actually use the Web Developer Toolbar for Firefox, but this give you similar functionality without having to use Firefox and having to install extensions, etc..)
If you still can't figure it out, let me know... and I'll look further and see if I can't get you fixed up.
fly my pretties
16th of July 2009 (Thu), 17:43
Todd thanks for the link, that is an exceptional resource. I had no idea things like that existed. Thanks again.
arnie12
17th of July 2009 (Fri), 11:02
No offense, but that is pretty shortsighted. I don't want to exclude an entire group of people based purely on their browser preference. That is a terrible business move.
What amounts to a small amount of effort on my part results in twice the amount of people being able to view my website. I like to stick two fingers up to Microsoft as much as the next man, but not at the cost of potential business.
Why is that short sighted? You could make some money doing photography with the time spent optimizing for an old browser AND you're doing something for the internet by adhering to standards (and making every one's life better in the long run). I would call catering to IE6 short sighted :rolleyes::cool:.
Remember: IE6 is not supported by Microsoft anymore, is quirky, is full of nasty security holes that are actively being exploited. Forcing users to get rid of that browser is a good thing.
Todd Lambert
17th of July 2009 (Fri), 11:12
Why is that short sighted? You could make some money doing photography with the time spent optimizing for an old browser AND you're doing something for the internet by adhering to standards (and making every one's life better in the long run). I would call catering to IE6 short sighted :rolleyes::cool:.
Remember: IE6 is not supported by Microsoft anymore, is quirky, is full of nasty security holes that are actively being exploited. Forcing users to get rid of that browser is a good thing.
Yes, true on all accounts. However, the usage percentages are still too high for IE6 users to effectively rule them out.
We're getting closer, but it's not time yet.(coming from someone who makes their living building websites) - Believe me, I'd love to drop that browser support, but at this time, too many clients need those users or, are those users... so I can't drop the support.
I believe in a year or so(I'm guess-speculating), we'll be able to finally drop official support - leaving it as an upgrade option for our sites.
Mocows
17th of July 2009 (Fri), 11:26
I haven't taken a look at the site yet but if you've used firebug in firefox during development, you should take a look at firebug lite since it works under ie6/7/etc...
I've used it before for weeding out random issues in ie6 but it's not really meant for an overhaul project.
http://getfirebug.com/lite.html
Faolan
17th of July 2009 (Fri), 11:33
I generally don't bother to develop for IE 6, I just give them a plain stylesheet removing the eye candy that's used for the 'full' site. Saves time and grief, not quite elegant but it gets the job done.
It's mostly corporations who are hanging on to IE more than home users and that's because they've got shoddy software that's not been properly developed.
habsfan93
17th of July 2009 (Fri), 14:01
I gave up on IE 6 recently. The layout of my photoblog is a little off in IE 6, but I just can't be bothered to completely rearrange the code just to conform to an outdated browser who's market share is dwindling every day. The site looks fine in IE 7 and 8 also, so that's always a bonus :D
RDKirk
17th of July 2009 (Fri), 14:10
It's mostly corporations who are hanging on to IE more than home users and that's because they've got shoddy software that's not been properly developed.
A heck of a lot of potential clients are browsing from work....
tracknut
17th of July 2009 (Fri), 14:33
A heck of a lot of potential clients are browsing from work....
This is an interesting point, that bears out for me. I have tallied up when I get the most orders from my customers, and Mondays, by a good margin, are the day. And it's not because I push out images Sunday night or anything... I'm convinced that folks are busy on the weekend, and when they're sitting at work Monday with nothing to do (or the boss is away), they decide to surf the net.
Dave
Faolan
17th of July 2009 (Fri), 14:34
A heck of a lot of potential clients are browsing from work....
That's what I mean, I know of a 'company' who's still using IE6 because their front for their database only works in that! It's also the reason they've not moved to Vista despite getting about 400 new PCs more than capable of running the OS. They have over 70,000 users... That's just locally.
They will actively block usage of any other browser, citing security issues ironically enough.
This is why I do an alternative sheet, but also have a hidden layer explaining that they are viewing a 'simplified' website.
This is particularly funny in light of this thread:
Internet Explorer on Flickr... (http://www.flickr.com/photos/robotjohnny/3629069606/sizes/o/)
Hikin Mike
18th of July 2009 (Sat), 02:28
I found a few days ago that my websites (I have several) wouldn't display properly in IE6....big time. Since 50% of my viewers use IE and 25% of those use IE6, I better fix it. I found a program (thanks Todd) that allowed my to look at older browsers. I fixed the bug and I'm now back in business.
fly my pretties
18th of July 2009 (Sat), 08:27
Why is that short sighted? You could make some money doing photography with the time spent optimizing for an old browser AND you're doing something for the internet by adhering to standards (and making every one's life better in the long run). I would call catering to IE6 short sighted :rolleyes::cool:.
Remember: IE6 is not supported by Microsoft anymore, is quirky, is full of nasty security holes that are actively being exploited. Forcing users to get rid of that browser is a good thing.
To be honest, I just don't really care. It took me less than a day to make my site work in IE6, so I consider that time well spent. I'd consider it quite arrogant on my part to insist that users upgrade their browser just to view my work.
Nah, I'll stick with my way.
vBulletin® v3.6.12, Copyright ©2000-2012, Jelsoft Enterprises Ltd.