<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Allen Huang wrote:
<blockquote cite="mid20050509173013.23037.qmail@web21128.mail.yahoo.com"
type="cite">
<div>I just want to show my root URL address whenever people browse
into other pages of my site. How do I do this in dtml or python script
or external method??</div>
<p> </p>
<hr size="1"></blockquote>
Allen,<br>
<br>
You can use index_html as a "call dispatcher". Each ZPT, DTML, etc
form's action should = "." or "index_html". <br>
<br>
Example:<br>
// .................................<br>
EditForm<br>
// .................................<br>
<head><br>
<script type="text/css"><br>
function Process() }{<br>
document.form.action_type.value = "Process"<br>
document.form.submit()<br>
}<br>
function Cancels() }{<br>
document.form.action_type.value = "Cancel"<br>
document.form.submit()<br>
}<br>
</head><br>
<body><br>
<h1>my big page</h1><br>
..<br>
<form action="index_html" method="post><br>
<input type="hidden" name="caller" value="editform"<br>
<input type="hidden" name="action" value=""<br>
.<br>
.<br>
<input type="button" onClick="process();return false;"
value="Process"><br>
<input type="button" onClick="cancel();return false;"
value="Cancel"><br>
<br>
</form><br>
# -------------------------------------<br>
index.html (i use python for this)<br>
# -----------------------------------<br>
request = context.REQUEST<br>
if caller == "editform":<br>
if action_type=="process"<br>
return context.Main(context,request)<br>
if caller == 'someotherform"<br>
return context..SomeOtherForm(context,request) <br>
<br>
etc<br>
<br>
In this way, you always get your apps root directory as the url.
index_html handles all requests. <br>
<br>
David<br>
<br>
<br>
</body>
</html>