Save {link} macro output to {var} variable in latte?

Notice: This thread is very old.
bukaJ
Backer | 52
+
0
-

I have much complicate {link} macro with lot of parameters. I dont want repeat this code n-times in template but i need put same link to more anchors in page. Is possible some way to save {link} to variable in latte syntax?

Just like as

{var $xyz = {link ...}}

I know, this example is not working.

Now i building link in presenter, that is working good, but i dont want keep that in presenter.

Eda
Member | 213
+
0
-
{capture $xyz}{link ...}{/capture}

:-)

enumag
Member | 2118
+
0
-
{var $xyz = $control->link(...)}
bukaJ
Backer | 52
+
0
-

Yeah. That's it!

enumag wrote:

{var $xyz = $control->link(...)}