[Zope] What's wrong with this code?

Helge Tesdal tesdal@stud.ntnu.no
Thu, 3 Feb 2000 23:14:11 +0100 (MET)


This is a part of the navbar on our site. When I try to access this
directly through a folder (without the header), Zope seems to go into an
seemingly infinite loop. Let's call the navbar 'test', and put it in the
root folder. It contains the code below. Then make a folder testfolder,
and call the navbar like this

  http://machine/testfolder/test

On our machines, Zope goes into an infinite loop. By removing lines, it
seems to recover from the "loop" more quickly. Seems like a n^x loop,
where n is the number of lines.

By removing the <dtml-in PARENTS skip_unauthorized> part it works. Is this
somehow iterating all the lines in the dtml-method?

Normally this is not a problem, as the header adds the <html> tags, which
seems to make it work, but what worries me is that anybody can stop our
site by trying to access this directly.

Here's the code of the navbar:

<dtml-unless expr="PARENTS[0]==PARENTS[-1]">
<dtml-if "meta_type == 'Artist'">
  <dtml-call "REQUEST.set('artist_alias', id)">
<dtml-else>
  <dtml-in PARENTS skip_unauthorized>
    <dtml-if "meta_type == 'Artist'">
      <dtml-call "REQUEST.set('artist_alias', id)">
    </dtml-if>
  </dtml-in>
</dtml-if>
</dtml-unless>
<!------ Start of artist admin navbar ------->
     <table
border="0" width="100%" bgcolor="#000000" cellspacing="0" cellpadding="0">
        <tr>
          <td width="100%">
            <table border="0" width="100%" cellspacing=1 cellpadding=3>
              <tr bgcolor="#7D8DAF" align="center" valign="center">
                <td width="100%">Manager-meny</td>




--
Helge Tesdal
tesdal@stud.ntnu.no