RE: Section Property First

From: Date: Mon, 25 Feb 2002 00:35:12 +0000
Subject: RE: Section Property First
References: 1  Groups: php.smarty.general 
Request: Send a blank email to php-smarty-general+get-2842@lists.php.net to get a copy of this message
It should work in all of them, although I'm not sure how long it will continue to be supported into future versions. This syntax is no longer in the documentation. -----Original Message----- From: Kai Kramhoeft [mailto:kai@agentpark.de] Sent: Sunday, February 24, 2002 7:14 AM To: smarty@lists.ispi.net Subject: [smarty] RE: Section Property First Hello Monte, {if %listing.first%} works fine. Thank you very much! Is this syntax supported in all Smarty versions ? I am using it as {if !(%listing.first%)} now. Kind Regards, Kai. ----- Original Message ----- From: Monte Ohrt To: smarty@lists.ispi.net Sent: Sunday, February 24, 2002 7:33 PM Subject: [smarty] RE: Section Property First I don't think the {$smarty.section.foo.bar} syntax is supported in 1.4.6. Upgrade Smarty, or use {if %listing.first%} -----Original Message----- From: Kai Kramhoeft [mailto:kai@agentpark.de] Sent: Sunday, February 24, 2002 6:08 AM To: smarty@lists.ispi.net Subject: [smarty] Section Property First Hello! I am running into a problem using "section property first". It doesnt seem to work in my source. I am using Smarty 1.4.6. If it is the first iteration I want to print out something different than its another iteration. Here is my source: ---------------------------------------------------------------------- ---------------------------------------------------------------------------- ------------- {section name=listing loop=$rows} <-- LOOK HERE <tr> <td width="50%" align="center">{$rows[listing].title}</td> <td width="12%" align="center"><a href="link_edit.php?action=edit&rid={$rid}&lid={$rows[listing].id}"> Editieren </a> </td> <td width="12%" align="center"><a href="link_delete.php?action=delete&rid={$rid}&lid={$rows[listing].id}"> L&ouml;schen </a></td> {if $smarty.section.listing.first} <--- LOOK HERE <td width="12%" align="center"><a href="link_show.php?action=up&rid={$rid}&lid={$rows[listing].id}&position={$ rows[listing].position}"> UP </a></td> {else} <td>&nbsp;</td> {/if} <td width="12%" align="center"><a href="link_show.php?action=down&rid={$rid}&lid={$rows[listing].id}&position= {$rows[listing].position}"> DOWN </a></td> </tr> {/section} ---------------------------------------------------------------------- ---------------------------------------------------------------------------- ------------------- Kind Regards, Kai ________________________________________________ Agentpark - Ihr Partner fuer professionelle Java Loesungen ________________________________________________ Kai Kramhoeft kai@agentpark.de Hoekerstr. 7 http://www.agentpark.de 27568 Bremerhaven Tel.: 0471-9515068 --- You are currently subscribed to smarty as: monte@ispi.net To unsubscribe send a blank email to $subst('Email.Unsub') Visit Smarty's homepage at http://www.phpinsider.com/php/code/Smarty/ --- You are currently subscribed to smarty as: kai@agentpark.de To unsubscribe send a blank email to $subst('Email.Unsub') Visit Smarty's homepage at http://www.phpinsider.com/php/code/Smarty/ --- You are currently subscribed to smarty as: monte@ispi.net To unsubscribe send a blank email to $subst('Email.Unsub') Visit Smarty's homepage at http://www.phpinsider.com/php/code/Smarty/

« previous php.smarty.general (#2842) next »