[Zope] Unauthorized problem

Gilles lavaux Gilles lavaux" <gilles.lavaux@esrin.esa.it
Wed, 13 Oct 1999 11:15:42 +0200


(Sorry, I send this also  to zope-dev by mistake.)

Hello,

Moving stuffs from zope1 to zope2 I got an unauthorized problem: I do a
search with the ZopeFind method in folder where I have a lot of rights. I
use a 'formatResult' method with the code bellow. The problem appear when I
try to acess properties (the title) of the documents I found. If I am
manager it works. giving ALL possible rights to my user doesn't solve the
problem.

I try to read the document properties (title) with a <dtml-with
"sequence-key"> <dtml-var title> </dtml-with>

yesterday I had problem using images inside the 'tree' tag, today problem
accessing object properties inside the 'with' tag. Is there more
problems/rules with the tags in zope2 than in zope1 or is it just me?

The code from my findFormat is bellow, thanks for any info:

<!--#var AUTHENTICATED_USER--><br>
<b><u>Search result from</u> <font color="#ff0000"><!--#var
curr_dir--></font>:</b><br>
<!--#call "REQUEST.set('curr',_['curr_dir'])"-->
<blockquote>
<!--#try-->
  <!--#call
"REQUEST.set('tmp_res',ZopeFind(this(),obj_ids=_['obj_ids'],search_sub=_['se
arch_sub'],obj_searchterm=_['obj_searchterm'],obj_metatypes=_['obj_metatypes
']))"-->
  Found <!--#var "_.len(_['tmp_res'])"--> candidate(s)<br>
  <!--#call "REQUEST.set('total',0)"-->
  <!--#in "_['tmp_res']" -->
   <!--#if "_.len(_['obj_keyword']) == 0"-->

    <!--#if "obj_metatypes=='DTML Document'"-->
      <!--#call "REQUEST.set('curr_dir',_['curr']+'/'+_['sequence-key'])"-->
      <!--#var GetParent-->
      <!--#var GetName-->
      <a href="<!--#var curr_parent-->/ShowDoc?doc_id=<!--#var
curr_name-->&curr_dir=<!--#var curr_parent-->&REFRESH=YES&VIEW=DOC">
<!--#var sequence-key--></a>
    <!--#else-->
      <a href="<!--#var curr-->/<!--#var sequence-key-->"> <!--#var
sequence-key--></a>
    <!--#/if-->
TEST: <!--#var "_['curr']+'/'+_['sequence-key']"--><br>
THIS IS THE PROBLEM:
    <!--#with "_['curr']+'/'+_['sequence-key']"-->
      &nbsp;&nbsp;'<!--#var title-->'<br>
    <!--#/with-->
   <!--#else-->etc....


Gilles Lavaux