Ticket #379 ( Accepted )

Short Description Surferscript Does not Function Correctly
Entered By: Big Kahuna When: 1999-09-02 10:52:32 Build: 2.0.5A GA
Categories Type: Problem   Department: Product   Category: SurferScript
Description
I had a situation where I had a </teloop> surferscript tag right before a <teelse> and what happened when I coded a <tebreak> inside the <teloop> is it executed the code after the <teelse> instead of cascading down thru the </teif>'s to exit out of the nested <teif> structure.  See code below:

<teif .....>
  <teloop col first=text_length-2 last=0 step=-1>
    <teset titlecount = titlecount + 1>
    <tebreak>
  </teloop>
<teelse>
  <teset item_found = 1>
</teif>

In this case, when the <tebreak> was executed, control went to the <teelse> and executed the <teset item_found = 1>

A work around for this was the following:

<teif .....>
  <teloop col first=text_length-2 last=0 step=-1>
    <teset titlecount = titlecount + 1>
    <tebreak>
  </teloop>
<!--dummy teset for teloop -->
  <teset titlecount = titlecount>
<teelse>
  <teset item_found = 1>
</teif>

After adding the 
 
Append By: WindSurfer  When: 1999-09-07 12:05:45  New Status: Accepted
Comment Will let you know when the bug has been fixed and the enhancement implemented.

Thanks for the report!