Cool way to detect if someone is registered for any event.
I got this from Noah with our TR mobile app project. I would have done this in a way dumber way.
[[?[[T12:[[S39:0*#000000*10pt*true*1*0*0*Events:true::::]]]]:: href=::::T]]
[[S39:0*#000000*10pt*true*1*0*0*Events:true::::]] <-- Generates a list widget of the TR events the user is registered for. In this case with a maximum of 1 entry. That's all we need.
[[T12]] <-- Converts the widget html into lower case.
[[? ... href=::::T]] <-- Looks for any occurrence of an href link to an event in the widget html.
Using S39 - something that generates a widget that would usually be displayed on a page - in the context of a conditional like this is the cool bit.
BPM
Comments
There are no comments yet