<!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="#000066">
<font size="-1"><font face="Verdana">You might want to use index_html
rather than index.html in this example. The dot means other things in
Python, and index.html is a carryover from filesystem webservers. My
impression is that the acquisition mechanism doesn't like ids with a
dot, in some circumstances.<br>
<br>
Not trying to nit-pick, just got hung-up on that item myself once
before.<br>
<br>
...or maybe that's not true anymore and has been allowed for...<br>
<br>
HTH,<br>
<br>
-Jon<br>
<br>
<br>
</font></font><br>
Peter Bengtsson wrote:
<blockquote
cite="midbc95c2800511250839q5213005g3c8b04244c747e50@mail.gmail.com"
type="cite">
<pre wrap="">folder = getattr(context, 'b')
adder = folder.manage_addProduct['OFSP'].methodAdd
adder('index.html', 'Some title')
That creates it with default content. To change it you'll have to call
dtmlm = getattr(context, 'index.html')
dtmlm.manage_edit("bla bla bla bla bla", 'Same title')
# or
f = open('/tmp/foobar.html')
dtmlm.manage_upload(f)
On 11/25/05, Martin Koekenberg <a class="moz-txt-link-rfc2396E" href="mailto:martin@digital-adventures.nl"><martin@digital-adventures.nl></a> wrote:
</pre>
<blockquote type="cite">
<pre wrap=""> Hello,
I don't have any Python experience yet, so who has a solution for this
'problem'.
Example:
I 've 3 folders a, b & c.
I want to create a dtml document in a folder by a form. The folder is a
variable in my form.
The formis no problem, the form action is no problem. The python script to
craete that document is my problem.
How can I create a DTM Document in a variable container ?
Regards,
Martin Koekenberg
_______________________________________________
Zope maillist - <a class="moz-txt-link-abbreviated" href="mailto:Zope@zope.org">Zope@zope.org</a>
<a class="moz-txt-link-freetext" href="http://mail.zope.org/mailman/listinfo/zope">http://mail.zope.org/mailman/listinfo/zope</a>
** No cross posts or HTML encoding! **
(Related lists -
<a class="moz-txt-link-freetext" href="http://mail.zope.org/mailman/listinfo/zope-announce">http://mail.zope.org/mailman/listinfo/zope-announce</a>
<a class="moz-txt-link-freetext" href="http://mail.zope.org/mailman/listinfo/zope-dev">http://mail.zope.org/mailman/listinfo/zope-dev</a> )
</pre>
</blockquote>
<pre wrap=""><!---->
--
Peter Bengtsson,
work <a class="moz-txt-link-abbreviated" href="http://www.fry-it.com">www.fry-it.com</a>
home <a class="moz-txt-link-abbreviated" href="http://www.peterbe.com">www.peterbe.com</a>
hobby <a class="moz-txt-link-abbreviated" href="http://www.issuetrackerproduct.com">www.issuetrackerproduct.com</a>
_______________________________________________
Zope maillist - <a class="moz-txt-link-abbreviated" href="mailto:Zope@zope.org">Zope@zope.org</a>
<a class="moz-txt-link-freetext" href="http://mail.zope.org/mailman/listinfo/zope">http://mail.zope.org/mailman/listinfo/zope</a>
** No cross posts or HTML encoding! **
(Related lists -
<a class="moz-txt-link-freetext" href="http://mail.zope.org/mailman/listinfo/zope-announce">http://mail.zope.org/mailman/listinfo/zope-announce</a>
<a class="moz-txt-link-freetext" href="http://mail.zope.org/mailman/listinfo/zope-dev">http://mail.zope.org/mailman/listinfo/zope-dev</a> )
</pre>
</blockquote>
<br>
<pre class="moz-signature" cols="72">--
Jonathan Cyr
<a class="moz-txt-link-freetext" href="http://www.cyr.info">http://www.cyr.info</a>
<a class="moz-txt-link-freetext" href="http://www.weddingweblog.com">http://www.weddingweblog.com</a>
<a class="moz-txt-link-abbreviated" href="mailto:cyrj@cyr.info">cyrj@cyr.info</a></pre>
</body>
</html>