Membership plugin question
2 posts by 2 authors in: Forums > CMS Builder: Plugins & Add-ons
Last Post: November 27, 2011 (RSS)
Hello, i'm currently using CMS Builder and Membership plugin, with work great.
I have another section editor call "Blogs", and i would like to give access to this section to my member.
Is it possible? and how to do it.
Actually, all the infos for each member are in the same table 'accounts'.
I have another section editor call "Blogs", and i would like to give access to this section to my member.
Is it possible? and how to do it.
Actually, all the infos for each member are in the same table 'accounts'.
Re: [willbegood] Membership plugin question
By Jason - November 27, 2011
Hi,
Yes, there are two ways you can do this:
1) You can give them access AFTER the account is created by going into their user record in the accounts table. Under "Section Access" you can either give them access to all sections or set their access to "By Section" and then give them access for the "Blogs" section.
2) You can give them access while creating their account with the membership plugin. In the signup form, you should see some code that looks like this:
For one of these lines, replace _sample with "blogs" and set an access level (0 for none, 6 for author, and 9 for editor).
Hope this helps get you started.
Yes, there are two ways you can do this:
1) You can give them access AFTER the account is created by going into their user record in the accounts table. Under "Section Access" you can either give them access to all sections or set their access to "By Section" and then give them access for the "Blogs" section.
2) You can give them access while creating their account with the membership plugin. In the signup form, you should see some code that looks like this:
// create accesslist entry
// replace '_sample' with the table you want the user to access
// replace '6' with the access level they should have: 0=none, 6=author, 9=editor
// replace '1' with the max listings they are allowed
mysql_query("INSERT INTO `{$TABLE_PREFIX}_accesslist`
(userNum, tableName, accessLevel, maxRecords, randomSaveId)
VALUES ($userNum, 'all', '1', NULL, '1234567890'),
($userNum, '_sample', '6', 1, '1234567890'),
($userNum, '_sample', '6', 1, '1234567890'),
($userNum, '_sample', '6', 1, '1234567890')") or die("MySQL Error Creating Access List:<br/>\n". htmlspecialchars(mysql_error()) . "\n");
For one of these lines, replace _sample with "blogs" and set an access level (0 for none, 6 for author, and 9 for editor).
Hope this helps get you started.
---------------------------------------------------
Jason Sauchuk - Project Manager
interactivetools.com
Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/
Jason Sauchuk - Project Manager
interactivetools.com
Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/