Randomly missing style sheet

A place for discussion about skinning and design. Before posting questions here you should review the documentation about creating skins.

This thread is closed to new posts. You must sign in to post in the forums.
10/25/2009 3:04:06 PM
Gravatar
Total Posts 190

Randomly missing style sheet

Hi All,

I'm experiencing something very strange with some recent updates I made. I'm using the mojosuperfish for dropdown menus and it seems the style sheet is only sometimes being applied. I can pull up the page in any browser on some machines and it looks fine (browser and version doesn't seem to be a factor). At work it looks fine and I tried it at a friend's house. Both Windows XP and IE 8 or Firefox 3. But I bring the page up at home (XP and Vista with IE8, Firefox 3 and Chrome) and I just get a vertical unordered list with no style applied. The mouseover works for showing and hiding submenus, but no style is applied. I even tried it at the Mac store in Safari today and that didn't work either. I'm really puzzled why it seems I only get the style sheet from some locations and not others. Anyone seen anything like this?

Thanks,

John

Here's a link if it helps: http://redesign.metc.state.mn.us/

10/25/2009 4:05:47 PM
Gravatar
Total Posts 18439

Re: Randomly missing style sheet

Hi John,

First I'd like to say it looks great on my Win 7 64bit machine using Chrome! Hope you will let me link to it when it goes live.

Since it is working for me its hard to guess what the problem is. The way I would troubleshoot the problem is on a machine where it doesn't work, view the source of the rendered page and grab the url for the CSS, I get http://redesign.metc.state.mn.us/Data/Sites/1/skins/MetroTransitMain/csshandler.ashx?skin=MetroTransitMain

paste the url into the browser navigation and see what you get when you try to view the css, do you see css or do you get an error?

Also what version of mojoPortal?

Hope it helps,

Joe

10/25/2009 4:43:20 PM
Gravatar
Total Posts 190

Re: Randomly missing style sheet

Hi Joe,

I have pretty recent code. I updated from svn yesterday and pushed that out to the test site. I put the CSS handler in the address bar and I get the one line style sheet, but there are no rules for sf-menu. That whole part is missing. It's positively dumbfounding. What's odd is that it is consistently missing from home on any computer or browser.

There's a lot work yet to be done on this site but we're hoping to launch just after the first of the year. I'd certainly be happy to have you feature the site. It's not 3M or BestBuy, but I think the Twin Cities Transit on mojoPortal should be pretty cool.

Thanks again,

John

10/25/2009 6:07:51 PM
Gravatar
Total Posts 190

Re: Randomly missing style sheet

Aha, I read through the css some more and found that an older version of the css for the stylemenu.css file is being returned. I just need to figure out how that is being cached and I think I can clear it out. (browser and server css caching is false in the web.config)

10/25/2009 6:17:04 PM
Gravatar
Total Posts 18439

Re: Randomly missing style sheet

Hi John,

Ah ok, browser cache on the machines may have happened before you set those variables so it would take clearing the cache of the browser on those machines. But there is a trick that can solve it instantly, copy the skin and rename it like yourskinname_v2, then set your site to use the new version, since the path will be different it will not already be in the cache on any machine.

Hope it helps,

Joe

10/25/2009 7:22:13 PM
Gravatar
Total Posts 190

Re: Randomly missing style sheet

I don't think it's caching on the browser. The Mac at the Apple store today has certainly never seen this page before and it still showed the nav with no style. It's somehow cached on the server. I may need to recycle IIS or something.

<<Oh, another thought. We have a proxy server. That could be caching something. That might explain why I see it correctly inside the network but not out. Though it doesn't really explain why some people outside the network can still see the new stuff.>>

10/26/2009 8:04:17 AM
Gravatar
Total Posts 18439

Re: Randomly missing style sheet

Hi John,

On thing I notice that could be the problem, the url in your page for the jQuery UI css has an extra /

'http://ajax.googleapis.com/ajax/libs/jqueryui/1.7.2/themes//ui.all.css'

In my sites and when I test locally I get the correct url

'http://ajax.googleapis.com/ajax/libs/jqueryui/1.7.2/themes/ui.all.css'

I think some browsers are more forgiving of url mistakes like that and some are not.

I'm not sure how that extra / is getting in there on your site since its working fine here but I suspect that is the problem. The sf-menu stuff is for the superfish menu and the css for that comes from jqueryUI not from the mojoportal css.

Hope it helps,

Joe

10/27/2009 9:59:33 AM
Gravatar
Total Posts 190

Re: Randomly missing style sheet

That theme problem was an oversight. I downloaded a custom theme and just needed to set the "includeJQueryUI" to false in the stylesheet combiner. Somehow, still, the stylesheet with rules for the asp-net menu is being sent to my browser at home (and some others) even after deleting all the cached files on my computer and updating the code and restarting IIS. There has to be some file cached on the server that I missed deleting when I last updated the project on the test server. Even browsers visiting this site for the first time sometimes show the old code (that Mac at the Apple store). Maybe I'll try just deleting everything on the server and redeploying the whole site.

10/28/2009 2:04:55 AM
Gravatar
Total Posts 11

Re: Randomly missing style sheet

John,

You appear to have the problem fixed. I tried the site the other day and experienced the issues you were talking about for your drop down menus.

But I bring the page up at home (XP and Vista with IE8, Firefox 3 and Chrome) and I just get a vertical unordered list with no style applied. The mouseover works for showing and hiding submenus, but no style is applied.

I tried Joe's suggestion about removing the " extra / " and it had no effect.

Have just tried again and everything is working fine for me. xpsp3 IE8 and Firefox3

Nice site! One of the best I've seen with mojo.

10/28/2009 5:47:47 AM
Gravatar
Total Posts 18439

Re: Randomly missing style sheet

John,

If you do have a caching proxy server in front of your site it definitely could have been a proxy caching issue.

Best,

Joe

10/28/2009 9:06:26 AM
Gravatar
Total Posts 190

Re: Randomly missing style sheet

Thanks kinzie. It has quite a bit of work to go, but I think it's coming along well. And I agree, Joe. I believe the proxy was hanging onto that old style sheet. I'm going to assume the issue is put to rest and keep it in mind when I'm looking at the site from outside the network.

Thanks again

You must sign in to post in the forums. This thread is closed to new posts.