PDA

View Full Version : How to secure a cms widget


HeLLCiTo
11 Jan 2012, 08:05
I have an html widget :




Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------



and i want tha this widget only can see one group of users, i supose i hace to use a php widget.How can i do? i searched in the forum, but a didīt find anything.

thanks

kh99
11 Jan 2012, 14:13
If you just want the widget to have no content (or maybe a different message for other usergroups), you could make it a php widget and for the code do something like:



Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------





If you want the widget to completely disappear, you could copy the vbcms_widget_execphp_page template code to a new template, add:


Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------




Then configure your PHP widget and add your new template in the Template Name field, and make the code


Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------



In either case you need to set the Cache Refresh Time for the widget to 0.