Allen Huang wrote:
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??


Allen,

You can use index_html as a "call dispatcher".  Each ZPT, DTML, etc form's action should = "." or "index_html". 

Example:
// .................................
EditForm
// .................................
<head>
<script type="text/css">
function Process() }{
   document.form.action_type.value = "Process"
   document.form.submit()
}
function Cancels() }{
   document.form.action_type.value = "Cancel"
   document.form.submit()
}
</head>
<body>
<h1>my big page</h1>
..
<form action="" method="post>
<input type="hidden" name="caller" value="editform"
<input type="hidden" name="action" value=""
.
.
<input type="button" value="Process">
<input type="button" value="Cancel">

</form>
# -------------------------------------
index.html (i use python for this)
# -----------------------------------
request = context.REQUEST
if caller == "editform":
   if action_type=="process"
      return context.Main(context,request)
if caller == 'someotherform"
     return context..SomeOtherForm(context,request)   

etc

In this way, you always get your apps root directory as the url.  index_html handles all requests.

David


_______________________________________________
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )

Reply via email to