4 Replies - 1785 Views - Last Post: 19 December 2010 - 10:35 PM

#1 phr33zr  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 3
  • Joined: 28-September 10

CSS works in Firefox, but not in IE

Posted 08 December 2010 - 06:59 PM

The following code will work in firefox, but not internet explorer. Could anyone tell my why it doesn't work in IE or tell me how to correct it to work?
HTML Code:
<ul id="menu">
  <li><a href="index.php">Home</a></li>
  <li><a href="">Family</a>
    <ul>
    <li><a href="about-homepage.php">About Homepage</a></li>
    <li><a href="directory.php">Directory</a></li>
    <li><a href="events.php">Events</a></li>
    <li><a href="pictures.php">Pictures</a></li>
    <li><a href="pages.php">Pages</a></li>
    </ul>
  </li>
  <li><a href="company-about.php">Company</a>
    <ul>
    <li><a href="company-about.php">About Company</a></li>
    <li><a href="company-projects.php">Company Projects</a></li>
    <li><a href="company-portfolio.php">Company Portfolio</a></li>
    <li><a href="company-services.php">Company Services</a></li>
    </ul>
  </li>
  <li><a href="">Information</a>
    <ul>
    <li><a href="christmas-info.php">Christmas Info</a></li>
    <li><a href="feedback.php">Website Feedback</a></li>
    <li><a href="view-info.php">User Account Information</a></li>
    <li><a href="user-weather.php">Your Local Weather</a></li>
    </ul>
  </li>
</ul>


CSS Code:
ul {
  font-family: Arial, Verdana;
  font-size: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
  width: 25.0em;

}
ul li {
  display: block;
  position: relative;
  float: left;
 }
li ul { display: none; }
ul li a {
  display: block;
  text-decoration: none;
  color: #ffffff;
  border-top: 1px solid #ffffff;
  padding: 5px 15px 5px 15px;
  background: #2C5463;
  margin-left: 1px;
  white-space: nowrap;
}
ul li a:hover { background: #617F8A; }
li:hover ul {
  display: block;
  position: absolute;
}
li:hover li {
  float: none;
  font-size: 14px;
}
li:hover a { background: #617F8A; }
li:hover li a:hover { background: #95A9B1; }



Is This A Good Question/Topic? 0
  • +

Replies To: CSS works in Firefox, but not in IE

#2 drhowarddrfine  Icon User is offline

  • D.I.C Regular

Reputation: 39
  • View blog
  • Posts: 275
  • Joined: 28-July 10

Re: CSS works in Firefox, but not in IE

Posted 08 December 2010 - 08:55 PM

"Doesn't work" is not a technical term. What doesn't work? Are you using a doctype?

Having problems with IE is expected and the norm.
Was This Post Helpful? 1
  • +
  • -

#3 phr33zr  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 3
  • Joined: 28-September 10

Re: CSS works in Firefox, but not in IE

Posted 08 December 2010 - 09:17 PM

View Postdrhowarddrfine, on 08 December 2010 - 07:55 PM, said:

"Doesn't work" is not a technical term. What doesn't work? Are you using a doctype?

Having problems with IE is expected and the norm.


No i'm not using a doctype and the "hover" feature of the menu does not work. The 4 basic buttons of the menu come up, but the menu doesn't drop down when you hover over a menu button.
Was This Post Helpful? 0
  • +
  • -

#4 phr33zr  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 3
  • Joined: 28-September 10

Re: CSS works in Firefox, but not in IE

Posted 08 December 2010 - 09:33 PM

View Postdrhowarddrfine, on 08 December 2010 - 07:55 PM, said:

"Doesn't work" is not a technical term. What doesn't work? Are you using a doctype?

Having problems with IE is expected and the norm.


I solved the problem, it was the missing doctype.
Was This Post Helpful? 0
  • +
  • -

#5 Sadin56  Icon User is offline

  • D.I.C Head

Reputation: 12
  • View blog
  • Posts: 183
  • Joined: 19-December 10

Re: CSS works in Firefox, but not in IE

Posted 19 December 2010 - 10:35 PM

View Postphr33zr, on 08 December 2010 - 08:33 PM, said:

View Postdrhowarddrfine, on 08 December 2010 - 07:55 PM, said:

"Doesn't work" is not a technical term. What doesn't work? Are you using a doctype?

Having problems with IE is expected and the norm.


I solved the problem, it was the missing doctype.


Entering the proper doctype for the file can save you alot of trouble in the end
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1