You are viewing a plain text version of this content. The canonical link for it is here.
Posted to embperl@perl.apache.org by Ilia Lobsanov <il...@lobsanov.com> on 2000/05/14 00:42:37 UTC

Re: Embperl

Ok let me elaborate and correct my first case:

[$ foreach $i @someArray $]
<tr[$ if ($ctr%2 == 0) $] BGCOLOR="#cccccc"[$ endif $]>
  <td>...</td>
</tr>
[- $ctr++ -]
[$ endforeach $]

So the html (that should be produced) is fine. However, Embperl dies
with the error: </tr> without <tr>

Definitely, Embperl doesn't like absence of space at: <tr[$ 
-because that is the only difference. Put a space before [$ and it
works.


Ilia Lobsanov wrote:
> 
> Why doesn't this work:
> <tr[$ if ($ctr%2 != 0) $]BGCOLOR="#cccccc"[$ endif $]>
> 
> Yet this works:
> <tr [$ if ($ctr%2 != 0) $]BGCOLOR="#cccccc"[$ endif $]>
> 
> The only difference is the space between <tr and [$
> 
> Is this a bug in Embperl or me?
> 
> ilia.
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: embperl-unsubscribe@perl.apache.org
> For additional commands, e-mail: embperl-help@perl.apache.org