RE: [SMARTY] Dereferencing associative arrays? [2]
| From: | Josh Johnson | Date: | Tue, 15 Oct 2002 03:44:37 +0000 |
| Subject: | RE: [SMARTY] Dereferencing associative arrays? [2] | ||
| References: | 1 | Groups: | php.smarty.general |
| Request: | Send a blank email to php-smarty-general+get-6138@lists.php.net to get a copy of this message | ||
I've used the {capture} function (see the docs) to combine strings... I
was never able to find a better way (if there is, somebody tell me!):
{capture name="my_var"}url?var1={$var1)&var2={$var2}&blah=true{/capture}
Then $smarty.capture.my_var will contain the whole string.
-- Josh
-----Original Message-----
From: Michal Prinke [mailto:bogien@conecto.pl]
Sent: Monday, October 14, 2002 11:37 PM
To: Smarty
Subject: Re: [SMARTY] Dereferencing associative arrays? [2]
Josh Johnson wrote:
>
> It should be:
>
> {assign var="message" value=$user.name}
>
> Hope that solves your problem :)
But what if I want to combine string & variable data - e.g. like this:
{assign var="url" value="/phpbb/viewforum.php?f=$project.board_id"}
What should I write then?
Thanks for help!
--
Smarty General Mailing List (http://smarty.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php