|
Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon. |
|
View previous topic :: View next topic |
Author |
Message |
Spea Smarty n00b
Joined: 26 Sep 2003 Posts: 1
|
Posted: Fri Sep 26, 2003 12:01 pm Post subject: date_format in popup |
|
|
hi,
i want to use date_format in popup.
here is the code
Code: | <a href="test" {popup text="<b>Bis:</b> `$search.bis|date_format`"}>{$search.firma}</a> |
but it allways shows something like this:
`Arry.bis|date_format`
is it possible to use date_format in a poup, isn't it?
greetz
Spea |
|
Back to top |
|
messju Administrator
Joined: 16 Apr 2003 Posts: 3336 Location: Oldenburg, Germany
|
Posted: Fri Sep 26, 2003 1:07 pm Post subject: Re: date_format in popup |
|
|
Spea wrote: | is it possible to use date_format in a poup, isn't it? |
yes, but you cannot use modifiers inside backticks.
maybe this
Code: | <a href="test" {popup text=$search.bis|date_format:"<b>Bis:</b> %b %e, %Y"}>{$search.firma}</a> |
works. |
|
Back to top |
|
andre Smarty Pro
Joined: 23 Apr 2003 Posts: 164 Location: Karlsruhe, Germany
|
Posted: Fri Sep 26, 2003 2:31 pm Post subject: |
|
|
If you really need complex strings you can also try to use the {capture} plugin - but you should try to avoid it imho.
Code: |
{capture name="text"}
<b>Bis:</b> {$search.bis|date_format}
{ ... call some other stuff here if you want ... }
{/capture}
<a href="test" {popup text=$smarty.capture.text|trim}>{$search.firma}</a>
|
edit: COOL ... my 100st posting |
|
Back to top |
|
|
|
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
|