Forum Discussion
This is the long way around, but here are two ways to get at least some of the variable names. I am making the leap of faith that FreeMarker uses these. If you go into the admin, click on User Management, and either Edit an existing rank or Create a new one, then scroll down to the entry box for Ranking Forumla. If you click the Help Button you will see a pretty good list of variable names.
If the one you want is not there, you can also go to Metrics and likely then Advanced Metrics. If for instance you chose a Report Scope of Role, then picked a role from the list of existing roles in your community, and then any metric on the right, and finally clicked Generate Report, you will see the variable for getting a role - "role.id=" as well as the particular role id both in the URL, as well as in the heading on top of the chart. You can use this method to see the variable name for any of the metrics listed.
I said it was the long way around, and that is likely an understatement. But give those methods a try and let us know.
Thanks, I've now cracked it for 'rank'.
It took a little bit of messing around - but the code you need is "user.ranking.id"
To get the ranking ID - go into the User management, edit rank - in the URL you can see the ID number at the end.
So in my example "Newbie giffgaffer" rank = 41.
<#if user.ranking.id = 41 >Welcome to giffgaff <#else>Welcome handy giffgaffer </#if>
Or to include different rankings (this still needs a little more testing, but seems to work OK)
<#if user.ranking.id = 23 >Welcome apprentice giffgaffer</#if> <#if user.ranking.id = 41 >Welcome giffgaff newbie <#else>Welcome handy giffgaffer </#if>
I did try to map to min number of posts, however this is linked to the metric table, which I think makes it too hard and gave up.
Ideally I'd still like to crack this by registration date - if anyone has any suggestions for getting 'less than x date' to work - please let me know.
Related Content
- 2 months ago
- 2 months ago
- 6 months ago
- 11 months ago