Forum Moderators: open

Message Too Old, No Replies

absolute URL overhead?

         

scorpion

8:13 pm on Dec 4, 2002 (gmt 0)

10+ Year Member



If you have an HTML and all the URL's are mentioned explicitly (absolute URLs) and there are MANY of them, will the page load slower than if you used say ONE base href tag OR relative URL's? I mean the page will be larger in size, but will it load slower?

BlobFisk

10:09 am on Dec 5, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



There will be an addition of a few Kb for using absolute URLs but nothing too significant... that's assuming that many isn't in the region of many hundreds!

Rhys

10:54 am on Dec 5, 2002 (gmt 0)

10+ Year Member



My understanding is that putting absolute URLs forces the browser back to the server each time the page is refreshed but using relative URLs allows the browser to source from the cache, with a corresponding increase in load speed.
Obviously the page or graphic has to come from the server in the first instance, but once loaded it is stored in cache and referenced from there the next time it is wanted.
The down side of this practice is that if you later move the page to another folder, you will need to edit the relative HREFs.
If, for instance, you have a logo/pic on many pages there is a huge gain in letting the browser use the cache to load it for subsequent pages :)