I use the scheduler plugin in a wordpress site. Sometimes I display information that is available to everyone, but sometimes I want to display some information to members only.
Is there a way to show some events in the scheduler to website members only?
Yes, you can filter displayed events on client or server side.
Filtering them on server side is a bullet proof solution, you simply do not include information you don’t want to be displayed. If you are using our connectors I can show some sample code.
If there is no sensitive information or you are sure that users won’t browse javascript object you can simply filter events from rendering
scheduler.filter_day = scheduler.filter_week = scheduler.filter_month = function(ev_id, ev){
if(ev.important && !isMember()) // if there is some flag that event is important and isMember function returned false...
return false; // event won't be rendered
return true; // defult, event will be rendered
}
Best regards,
Ilya
Get a guaranteed answer from DHTMLX technical support team
under the most suitable support plan