Membership Plugin Question

14 posts by 2 authors in: Forums > CMS Builder
Last Post: September 12, 2012   (RSS)

By Jason - September 12, 2012

Hi,

I noticed that you're checking for 3 different fields (fellow, certified, associate). What type of fields are these?

Is there one "user type" field that you can use to distinguish users?

Thanks,
---------------------------------------------------
Jason Sauchuk - Project Manager
interactivetools.com

Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/

By Jason - September 12, 2012

Hi Meg,

No problem. The issue here was that checkboxes will always have a value of either 1 or 0, so you can change your if statement to look like this:

if ($CURRENT_USER['fellow']) {
$url = "/member/fellows.php";
}
elseif ($CURRENT_USER['certified']) {
$url = "/member/certified.php";
}
elseif ($CURRENT_USER['associate']) {
$url = "/member/associate.php";
}
else {
$url = "/member/subscriber.php";
}



It's important to note that if more than checkbox is checked, they'll be redirected to the last one found in the list.

Hope this helps
---------------------------------------------------
Jason Sauchuk - Project Manager
interactivetools.com

Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/

Re: [Jason] Membership Plugin Question

By meg - September 12, 2012

That's good to know. Thank you!