Speeding up cascading style sheets (Full Version)

All Forums >> [Web Development] >> Cascading Style Sheets



Message


mcconnac -> Speeding up cascading style sheets (11/14/2003 0:00:36)

Hi

I am using cascading style sheets (If this is the same as flying menus) with DreamWeaver, with about 5 initial levels, floating to a potential 4 sub levels from each of these, and a further 5-10 from these. The objective is so that the end users can see all the links, without having to click, only float across the topics to see where this takes them. After the pages load the first time, this does exactly what I needed, but the initial Java Loadtime (I assume Java) takes up to 5 seconds on screen (with T1), and I am getting complaints about the initial blank screen for such a long time. Can the code that has been inserted from the Dreamweaver simple tools to create these menus be changed into better code, or am I just doing something stupid?




bobby -> RE: Speeding up cascading style sheets (11/14/2003 17:13:48)

It sounds like you're using some kind of mixture of HTML, Java Script (probably not Java) and CSS (but I'm not as familiar with DW's features)

A CSS is just a text formatted document, usually only 6-8 Kb at the most... tho I've seen a few that are quite a bit larger. Not big enough to take 5 seconds over a T1.

If anything, a CSS should speed up your pages, because it cuts down on the minor bloat you get from all the <font> and <style> tags. Start adding DHTML or Java Script in addition to a CSS, and it could get pretty complicated.

The time lag could be a server issue, or your PC itself...

The T1 line will only transfer the files off of the server as fast as the server will allow... and JavaScript is processed in your browser locally... so that may be part of it.

I don't know that I'd call it stupid, but it sounds like the kewl factor is overshadowed by the increased load time... and maybe not worth it for your site...

[8|]




Nancy -> RE: Speeding up cascading style sheets (11/14/2003 18:36:16)

Additionally, if you are using tables it may be affecting how your site loads. If you have one main table, with nested tables inside, there will be a delay of anything showing up until the main table loads. The option would be to use individual tables for some things and "stack" them, rather than nesting.

In a large majority of cases, the CSS is not the cause of a delay in load time.

Nancy




gorilla -> RE: Speeding up cascading style sheets (11/14/2003 19:30:33)

In addition to the excellent points made above.

If you're talking about what I think you're talking about then it's a script based menuing system that also uses css. The delay is caused by the size of the script rather than the css. With css there will be a small initial load cost, thereafter none as it is cached.

A way of reducing the page load time on all pages after the first one your visitor sees is outlined here:

http://www.htmlgoodies.com/beyond/extjs.html

however I have to say that if you're on a T1 connection the download time (assuming a moderately ok server) should be negligible - sounds to me like the script is massive - you might like to think strongly about the last point bobby made. I am on a very very fast connection. in effect I sit a the end of a datapipe. With that sort of render time I simply leave. - Visitors on an ordinary connection are likely to too.




Page: [1]

Valid CSS!




Forum Software © ASPPlayground.NET Advanced Edition 2.4.5 ANSI
0.0625