When a DTML page containing a head tag is visited, without a trailing slash, the base href isn't set. When visited with a slash, it is:
>>> print http(r""" ... POST /+/zope.app.dtmlpage.DTMLPage%3D HTTP/1.1 ... Authorization: Basic mgr:mgrpw ... Content-Length: 497 ... Content-Type: multipart/form-data; boundary=---------------------------824954900632940947241835499 ... Referer: http://localhost:8081/+/zope.app.dtmlpage.DTMLPage%3D ... ... -----------------------------824954900632940947241835499 ... Content-Disposition: form-data; name="field.source" ... ... <html> ... <head></head> ... <body> ... <a href="eek.html">Eek</a> ... </body> ... </html> ... ... -----------------------------824954900632940947241835499 ... Content-Disposition: form-data; name="UPDATE_SUBMIT" ... ... Add ... -----------------------------824954900632940947241835499 ... Content-Disposition: form-data; name="add_input_name" ... ... dtml.html ... -----------------------------824954900632940947241835499-- ... """) HTTP/1.1 303 See Other ...>>> print http(r""" ... GET /dtml.html HTTP/1.1 ... Authorization: Basic mgr:mgrpw ... """) HTTP/1.1 200 OK ... <html> <head></head> <body> <a href="eek.html">Eek</a> </body> </html> <BLANKLINE>>>> print http(r""" ... GET /dtml.html/ HTTP/1.1 ... Authorization: Basic mgr:mgrpw ... """) HTTP/1.1 200 OK ... <html> <head> <base href="http://localhost/dtml.html" /> </head> <body> <a href="eek.html">Eek</a> </body> </html> <BLANKLINE>