Graphics On Error Pages

A couple of weeks ago I was trying to get graphics to show up on error pages, and after playing around a bit, i finally managed to. However, graphics only show up on the error page if you go to an incorrect address in the initial directory. If you type in any incorrect addresses in sub-directories (eg. www.mysite.com/doesnotexist/xxxx.html), the graphics don’t show up.

The site in question is http://www.ekhinos.com
If you navigate through any of the main headings, you will clearly see the sub-directories. Im trying to get the logo to show up on the error pages, whatever you type in.

Any help would be very much appreciated.


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

On Oct 29, 2007, at 2:14 PM, zacbest wrote:

A couple of weeks ago I was trying to get graphics to show up on
error pages, and after playing around a bit, i finally managed to.
However, graphics only show up on the error page if you go to an
incorrect address in the initial directory. If you type in any
incorrect addresses in sub-directories (eg. www.mysite.com/
doesnotexist/xxxx.html), the graphics don’t show up.

The site in question is http://www.ekhinos.com
If you navigate through any of the main headings, you will clearly
see the sub-directories. Im trying to get the logo to show up on
the error pages, whatever you type in.

Any help would be very much appreciated.

Try adding a base HREF tag to your error page. They look like this:

 <base href="http://url.to.your.site/" />

Note the trailing slash. Very important!

If you’re using Freeway to create your error page, then use the Page

HTML Markup dialog, and add this right after the beginning of the
HEAD tag. Otherwise add it by hand in the same spot.

What’s happening here is that when you go to a bad URL, the 404 page
appears instead of that page – but the URL to the page is not
changed. So if your graphics are living in (site root)/Resources/,
and the URL says you are in (site root)/some/folder/here/, then the
404 page is going to look for the graphics it needs in (site root)/
some/folder/here/Resources/.

The base HREF tag tells the browser, “Every incomplete URL in this
page should be expanded by starting with this URL.”

Walter


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

My memory is failing me here but I had a similar problem some time ago, I think I just renamed the custom error page to 404.shtml

I will have to un- archive the site to see what I did.


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

On 29 Oct. 2007, 7:19 pm, Marcel wrote:

My memory is failing me here but I had a similar problem some time ago, I think I just renamed the custom error page to 404.shtml

That is most likely going to be a very server-specific solution. The Base HREF trick works on any Web server.

Walter


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

except the whacky part is that the < base href="/" / >

(spaces inserted because the auto preview wanted to ignore it)

So when you put in the base href it doesn’t get the script stuff that references “Resource/”


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Use the page / HTML markup dialog, but choose the after start head slot. That should get the base tag right after the opening tag.

Walter


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options