While testing your demo dbs I noticed one small flaw (?) in your technique of
constructing base url address for base element - you omit web server's port
number. So if web server use port number other than default, all the internal
links on page become broken. I know it's not so common case, but still better
to be prepared for the worst... ;-)
I use formula:
"<base href=\"http://" + Server_Name + @If(Server_Port = "80"; ""; ":" +
Server_Port) + "/" + @WebDbName + "/\">"
And of course, to be completely safe, one should check protocol used...