Re: [SMARTY] popup
| From: | Jochem Maas | Date: | Mon, 22 Nov 2004 09:40:02 +0000 |
| Subject: | Re: [SMARTY] popup | ||
| References: | 1 2 | Groups: | php.smarty.general |
| Request: | Send a blank email to php-smarty-general+get-11993@lists.php.net to get a copy of this message | ||
Bertrand Zuchuat wrote:
On 19 nov. 04, at 23:40, boots wrote:try: {foreach name=local key=key item=item from=$value.localisation} <acronym {popup caption=$smarty.const.LIBRARY|ucfirst fgcolor="#e2eeff" bgcolor="#D8EEFF" capcolor="#000677" text="Assuming $content is being sent as an array from your PHP code, it looks like your code isn't exactly what you posted but rather: {popup caption=$smarty.const.LIBRARY fgcolor="#e2eeff" bgcolor="#D8EEFF" capcolor="#000677" text="$content.library_name"} Where there are quotes around the text attribute value. If it is written as you posted, it looks like it should work.Hello, I use this code into my page: <td valign="top"> {foreach name=local key=key item=item from=$value.localisation} <acronym {popup caption=$smarty.const.LIBRARY|ucfirst fgcolor="#e2eeff" bgcolor="#D8EEFF" capcolor="#000677" text=" $item.library_name ($key)<br> $item.library_street<br> $item.postal_code $item.city<br> $item.phone"}>{$key}</acronym><br> {/foreach} </td>
$item.library_name ($key)<br>
$item.library_street<br>
$item.postal_code $item.city<br>
$item.phone"}>{$key}</acronym><br>
{/foreach}
Outside the popup function, the value $item.library_name is OK. Inside the foreach, the value is Array.library_name (isn't OK). Thank's for your help. Bertrand