[SOLVED] IE7 hover style not working

This is a discussion on "[SOLVED] IE7 hover style not working" within the Web Page Design section. This forum, and the thread "[SOLVED] IE7 hover style not working are both part of the Design Your Website category.



Go Back   Webforumz.com > Main Forums > Design Your Website > Web Page Design

Notices


Reply
 
LinkBack (1) Thread Tools
  1 links from elsewhere to this Post. Click to view. #1 (permalink)  
Old Dec 5th, 2007, 07:21
New Member
Join Date: Dec 2007
Location: South Africa
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
[SOLVED] IE7 hover style not working

Hi,

I've got a table with .png images in and loading styles from a css/main.css file.
I've successfully managed to change the background color of a div the images sits in when I hover over it with my mouse. This unfortunately only works in Firefox 2.0.0.11, but not in IE7.

How do I fix this?

Here's my css and htm code

CSS
Code: Select all
#styleImage {
     
    border:             1px solid grey;
    padding:            7px;
    margin:             5px;
    background-color:   #8DC4D8;

}

#styleImage:hover {
    
    background-color:   #E8E8E8;

}
HTM
Code: Select all
<table border="0" cellpadding="0" cellspacing="0" width="100%">
  <tr>
    <td align="center"><div id="styleImage"><a><img src="images/DOC.png" width="125" height="125" /></a></div></td>
    <td align="center"><div id="styleImage"><a><img src="images/HTML.png" width="125" height="125" /></a></div></td>
    <td align="center"><div id="styleImage"><a><img src="images/PDF.png" width="125" height="125" /></a></div></td>
    <td align="center"><div id="styleImage"><a><img src="images/RTF.png" width="125" height="125" /></a></div></td>
    <td align="center"><div id="styleImage"><a><img src="images/TXT.png" width="125" height="125" /></a></div></td>
  </tr>    
</table>
Thanx in advance
Reply With Quote

  #2 (permalink)  
Old Dec 5th, 2007, 07:35
Most Reputable Member
Join Date: Feb 2004
Location: Borneo
Age: 27
Posts: 1,608
Blog Entries: 2
Thanks: 0
Thanked 4 Times in 3 Posts
Re: IE7 hover style not working

We need your image as well to see the "actual" result. Could you host it somewhere please?
Last Blog Entry: ASP Programming Tips and Technique (Oct 26th, 2007)
Reply With Quote
  #3 (permalink)  
Old Dec 5th, 2007, 07:45
New Member
Join Date: Dec 2007
Location: South Africa
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Re: IE7 hover style not working

Can I zip and mail it to you instead?
Reply With Quote
  #4 (permalink)  
Old Dec 5th, 2007, 07:50
Most Reputable Member
Join Date: Feb 2004
Location: Borneo
Age: 27
Posts: 1,608
Blog Entries: 2
Thanks: 0
Thanked 4 Times in 3 Posts
Re: IE7 hover style not working

Or you could just zipped it and attach them in your next post
Someone else might need the file in order to help you.
When you post reply, scroll down to the page and you could see the "Manage Attachment" browse your zip file and upload them.
Last Blog Entry: ASP Programming Tips and Technique (Oct 26th, 2007)
Reply With Quote
  #5 (permalink)  
Old Dec 5th, 2007, 07:56
New Member
Join Date: Dec 2007
Location: South Africa
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Re: IE7 hover style not working

Thanx monie
Attached Files
File Type: zip IE7 problem.zip (198.3 KB, 3 views)
Reply With Quote
  #6 (permalink)  
Old Dec 5th, 2007, 08:15
Most Reputable Member
Join Date: Feb 2004
Location: Borneo
Age: 27
Posts: 1,608
Blog Entries: 2
Thanks: 0
Thanked 4 Times in 3 Posts
Re: IE7 hover style not working

Ahh... that probably your DOCTYPE problem!

What application(WYSIWYG) you used to code your page?
All you need to do is change your DOCTYPE from this:
Code: Select all
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
to this:
Code: Select all
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
That should make your day

You could read THIS to better understand the DOCTYPE
Last Blog Entry: ASP Programming Tips and Technique (Oct 26th, 2007)

Last edited by Monie; Dec 5th, 2007 at 08:18.
Reply With Quote
  #7 (permalink)  
Old Dec 5th, 2007, 08:34
New Member
Join Date: Dec 2007
Location: South Africa
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Re: IE7 hover style not working

Yeah monie! You are a star. Works perfectly

I user Activestate Komodo Edit4.1, but inserted the DOCTYPE part through a template in Komodo Edit. Is there another free code editor that you can recommend. I do php, js, htm, css, c# etc programming

I've been doing web development for about a year now and I must say I still have a lot to learn.

monie, can you maybe point out some important key areas, such as DOCTYPE, that I need to look in to, that is absolutely essential for web development.

Thanx so much. I really appreciate it!
Reply With Quote
  #8 (permalink)  
Old Dec 5th, 2007, 12:31
karinne's Avatar
SuperMember

SuperMember
Join Date: Jan 2007
Location: You know where
Age: 31
Posts: 4,617
Thanks: 0
Thanked 0 Times in 0 Posts
Re: IE7 hover style not working

About DOCTYPE

Choosing the best Doctype for your website

About and EDITOR

HTML Editors
Reply With Quote
  #9 (permalink)  
Old Dec 5th, 2007, 12:40
New Member
Join Date: Dec 2007
Location: South Africa
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Re: IE7 hover style not working

karinne,

thank you very much. I'll check them out
Reply With Quote
  #10 (permalink)  
Old Dec 6th, 2007, 01:40
Most Reputable Member
Join Date: Feb 2004
Location: Borneo
Age: 27
Posts: 1,608
Blog Entries: 2
Thanks: 0
Thanked 4 Times in 3 Posts
Re: [SOLVED] IE7 hover style not working

And if you are trying to find some other great text editor out there, check out his thread!
Last Blog Entry: ASP Programming Tips and Technique (Oct 26th, 2007)
Reply With Quote
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

LinkBacks (?)
LinkBack to this Thread: http://www.webforumz.com/web-page-design/62935-solved-ie7-hover-style-not-working.htm
Posted By For Type Date
IE7 hover style not working - CodingForums.com This thread Refback Dec 5th, 2007 09:10

Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] magical ie6 hover states AndrewChip Web Page Design 1 Mar 31st, 2008 13:03
Why Style sheet isnt working kaz Web Page Design 19 Dec 21st, 2007 01:10
[SOLVED] styling a div with a link and hover lister110 Web Page Design 6 Oct 31st, 2007 13:33
document.getElementById[objectID].style now working on Mozilla Browser yogeshid JavaScript Forum 1 May 25th, 2007 09:30
Div Style not working from External CSS duel Web Page Design 2 Mar 22nd, 2007 11:03


All times are GMT. The time now is 03:17.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC8
© 2003-2008 Webforumz.com : All Rights Reserved

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43