Today, someone created an index_html document in our Zope site which did not have any <html></html> tags or a <head></head> section. Grumble. The trouble was that their images were not showing up when requesting the folder as folderName and not as folderName/ I know that Zope adds a <base href="..."> when there is an html head section, but is the head section required? I notice that Apache, when a bare folder is requested, comes back with the folder with the trailing slash automatically. Is there a reason why Zope does not do this? Should I just be educating the newbie html coders, or is this a bug? _________________________________________________________________ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp.
Hi!
I know that Zope adds a <base href="..."> when there is an html head section, but is the head section required?
If there's no head, it is no valid HTML, which is ... not so good ... The base href is quite useful for Zope being able to handle relative URLs correctly, so I'd try to use it.
I notice that Apache, when a bare folder is requested, comes back with the folder with the trailing slash automatically. Is there a reason why Zope does not do this? Should I just be educating the newbie html coders, or is this a bug?
It is definitely no bug. And if you let Zope set its base href, the problem will not occur anyway. Correct HTTP would always be to use the trailing slash. Most servers will accept the URL without the slash and try to find a folder with that name, but that takes extra time. Joachim
Lee Harr writes:
... folder URL without trailing '/' ... I know that Zope adds a <base href="..."> when there is an html head section, but is the head section required?
I notice that Apache, when a bare folder is requested, comes back with the folder with the trailing slash automatically. Is there a reason why Zope does not do this? Should I just be educating the newbie html coders, or is this a bug? I do not think, it is a bug.
The alternative would be to use a redirect with the modified URL. It would be less efficient, make problems for request methods other then "GET" and cause messages in the mailing list about browser differences wrt. redirects (I just read one today)... Apache can safely use redirect, when an URL hit a folder (which probably only happens for "GET" requests). For Zope, it would be much more problematic. Dieter
participants (3)
-
Dieter Maurer -
Joachim Werner -
Lee Harr