Hi
I'm developing a plugin that load some video for the course
I only want this to load if the user owns the course
how can I check this in PHP so I can use that to restrict my content, I'm sure you guys already have a way since you do it already.
Thank you
Hi,
You mean the user is already enrolled in the course .
For this we have created a function "bp_course_is_member"
It takes two arguments course_id and user_id, so you can use this function like this:
if(!bp_course_is_member($course_id,$user_id))
return;
Hi
yes, that worked great thank you