[Zope] Solved! Thank the ZQR! but Redirect/not found...

Ethan Fremen mindlace@majordomo.net
Fri, 08 Oct 1999 12:59:15 +0100


Ethan Fremen wrote:
> Dan, thanks, but what I'm trying to achieve here is [...] a cloned document where
> the document itself has the properties to which I assign values.

Whohoo!  I knew the new ZQR would save me!  Thanks, Brian, David, Evelyn
and Stephen!

the answer is that manage_clone(ob,id,[REQUEST]) works on any object. 
So, for this case, you just use
manage_clone(template_id,REQUEST=['new_id'],REQUEST) and it works fine.
(this won't, of course, work for methods 'cuz they can't have their own
properties)

So, hehee, it works!  I was struggling with Zope and felt like giving
up, but now... I can use a variation of this product extensively
throughout my page, giving the 'any idiot can update' feature I
promised... 

I know it's a basic thing, but now I think I understand the object
approach better, and can start to see how to leverage it.

Thank you Zopistas!

...

However, not everything worked...
Why does this bit:<dtml-call
"RESPONSE.redirect('manage_main?update_menu=1')">

result in not found? The file does exist, and has all the appropriate
properties. If I do /path/to/created/document/manage_main?update_menu=1
everything works fine.

Traceback (innermost last):
  File /usr/local/src/Zope-2.0.0-src/lib/python/ZPublisher/Publish.py,
line 214, in publish_module
  File /usr/local/src/Zope-2.0.0-src/lib/python/ZPublisher/Publish.py,
line 179, in publish
  File /usr/local/src/Zope-2.0.0-src/lib/python/Zope/__init__.py, line
201, in zpublisher_exception_hook
    (Object: RoleManager)
  File /usr/local/src/Zope-2.0.0-src/lib/python/ZPublisher/Publish.py,
line 151, in publish
  File
/usr/local/src/Zope-2.0.0-src/lib/python/ZPublisher/BaseRequest.py, line
426, in traverse
  File /usr/local/src/Zope-2.0.0-src/lib/python/AccessControl/User.py,
line 373, in validate
    (Object: RoleManager)
  File
/usr/local/src/Zope-2.0.0-src/lib/python/ZPublisher/HTTPResponse.py,
line 510, in notFoundError
NotFound: (see above)
...

the source says a funny... 
<!--
who knows!
-->

-- 
Ethan "mindlace" Fremen
webworker