Smarty Forum Index Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon.

Concatenating within a Foreach

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> General
View previous topic :: View next topic  
Author Message
Nick W
Smarty Rookie


Joined: 23 May 2003
Posts: 22

PostPosted: Mon Sep 01, 2003 10:04 pm    Post subject: Concatenating within a Foreach Reply with quote

Hi everyone,

I'm trying to add to a string within a template so that I can look at the total length and use truncate on it: ---> it's easier with an example:

Code:

<option>
{foreach from=$array item=a}
:::I would like to add each {$a} here:::
{/foreach]
</option>


The problem is that once concatenated that dropdown can get pretty damn wide, so, I'd like to look at the whole text between the option tags and decide to truncate or not.

With me?

Help and advice sought Wink

Nick
Back to top
View user's profile Send private message
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> General All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group
Protected by Anti-Spam ACP