Solved

no css on first load of site

Posted on 2008-11-03
5
206 Views
Last Modified: 2012-05-05
So i am working with a team that have a site that is going to be rolled out soon.

I went to view the site for the first time on firefow3 on my mac and the home page loaded but it looked like the CSS was not loaded.

I refreshed the page and all worked fine.

I am worried that this has happened to a few peope and that this could happen when the site goes live.

Has anyone else seen simular situations like this and how have you solved it?

Also is there a way i can recreaet going to the site for the first tme as i have create the FF cache and it seems ok, but if i go t a virgin machine and hit the home page i see the problem.

W

0
Comment
Question by:willa666
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
5 Comments
 
LVL 7

Expert Comment

by:Valleriani
ID: 22867456
I know there was a bug in IE6 that causes this. But after updating IE6 it will solve this issue. Normally if it is IE6, you should be updating to IE7 anyways.

Are you seeing this on another browser? Perhaps a link would help so we can check it out. If your issue is in IE6, this was a bug by them, and was solved, but you'd need a up to date IE6.
0
 
LVL 6

Expert Comment

by:trickyidiot
ID: 22867935
Valleriani: The user specified this is an issue with FireFox - not IE.

Willa666: Can you include a link or  code snippet so we can see how you are referencing your CSS file?
0
 
LVL 44

Accepted Solution

by:
scrathcyboy earned 500 total points
ID: 22872933
To solve the issue on firefox not refreshing, simply look into Tools -> Options or Preferences, find out where FF is saving the cached data, close Firefox, and delete all files in that cached directory, then restart FF, and you will see the same issue crop up as if you first visited the site.

This kind of problem usually happens when the PATH to the CSS file is not specified correctly.  Say it is in a folder called "css" under the WWW root directory, then your path to the default.css is this --

<LINK rel="stylesheet" type="text/css" href="css/default.css">

No preceding dots or slashes, and DO NOT USE backslashes -- that is a microsoft quirk, the rest of web browsers use FORWARD slashes -- as in unix /this/path/to/your/file -- NEVER backslashes.  

That will almost certainly solve it -- if not, put all the CSS in the HEAD of the document to test, when you see FF is rendering it fine, you will realize it is either an ERROR in the CSS file, or a bad-formed path.
0
 
LVL 1

Author Comment

by:willa666
ID: 22874302
Hi scrathcyboy

I will give that a try today, fingers crossed, touch wood, etc etc :)

Ww

0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When writing CSS, there are a few simple rules that will make your life easier.    1. Using ‘* {box-sizing:border-box;}’. Using this will wrap all your elements in a nice little compact box-model that will give you the width you want, like so... …
This article discusses four methods for overlaying images in a container on a web page
In this tutorial viewers will learn how to style elements, such a divs, with a "drop shadow" effect using the CSS box-shadow property Start with a normal styled element, such as a div.: In the element's style, type the box shadow property: "box-shad…
In this tutorial viewers will learn how to embed custom externally-hosted Google Fonts using the Google Font API in CSS Go to the Google Fonts website at google.com/fonts: Browse or search based on font properties or name to find a suitable font for…

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question