Macro default and undefined variable

Ajax
Member | 57
+
0
-

Hello! I have a template:

{default $priceOrder = 'DESC'}

{block content}
<div id="content">
        <a n:href="this, orderByPrice => $priceOrder">{_'Order by price'}</a>
</div>

Tracy says Undefined variable: priceOrder

What I'm doing wrong? Thanks!

David Matějka
Moderator | 5701
+
+2
-

You have to put that {default} macro inside the block.

Comments

Ajax:

What a stupid mistake… Thanks!

4 years ago