I have a small web project where I have many pages and a ToC index / file. The toc file is at the root of my project at toc.html. Pages are distributed in several subdirectories and include toc c iframe.
The project does not need a web server, so I can create HTML code in the directory and view it in my browser. The problem is that I ran into XSS problems when JavaScript from toc.htmlwants to call a function on the page (violation of the same origin policy).
So, I added the tags basein the header with the relative URL to the directory in which toc.html. This works for Konqueror, but in Firefox I have to use absolute paths, or toc doesn't even display: (Here is an example:
<?xml version='1.0' encoding='utf-8' ?>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<base href="../" target="_top" />
<title>Project 1</title>
</head>
<body>
<iframe class="toc" frameborder="0" src="toc.html">
</iframe>
</body>
</html>
page. Firefox , , page/toc.html.
? , ( - ).