Forum Discussion
nickyates
Mentor
I had the same issue here and never did get to the bottom of it. Frustratingly im getting the same problem again while using an if/else block on another section of code. Any update on this would be very helpful
Henrik
12 years agoAdvisor
Hi,
I got the same issue. It seems to me that Lithium catch the error before Freemarker does.
I want to test if one node of the REST result exists:
<#assign user_ranking = rest("/users/id/${user.id}/ranking").ranking /> <#attempt> <#assign user_ranking_image_left = author_ranking.display.left_image.url?replace("http://www.cvous.com", "")?js_string /> <#recover> <#assign user_ranking_image_left = "" /> </#attempt> <#attempt> <#assign user_ranking_image_right = author_ranking.display.right_image.url?replace("http://www.cvous.com", "")?js_string /> <#recover> <#assign user_ranking_image_right = "" /> </#attempt>
But the "attempt" test will generate a "This widget could not be displayed" for anonymous or non admin members.
I don't even know why it works for admin member.
Have a nice day!
Henrik
Related Content
- 5 months ago
- 2 years ago
- 2 years ago