[SOLVED] automatic add new users to a plan

13 years 9 months ago #134329 by kbotnen
Hi,

I have the following question:

Is there any way to automatically add a new registered user to a subscription plan without the user have to choose the plan?

I use cbsubs as ACL system so the users are not aware of plans, subscription etc.

If there is no way to do this through cb / cb subs I could probable alter comprofiler to fire a custom sql query upon registration, which leads me to the next question:

Is there other tables than "cbsubs_subscriptions" I have to add the new user to?

-Kristian-

Post edited by: krileon, at: 2010/06/01 15:36

Please Log in to join the conversation.

13 years 9 months ago #134336 by krileon
Replied by krileon on topic Re:automatic add new users to a plan

Is there any way to automatically add a new registered user to a subscription plan without the user have to choose the plan?

Set the plan as "Default" should result in the user automatically obtaining the plan. It should be free lifetime and you should disable users without subscriptions via CBSubs > Settings > Global. This might provide you with what you're wanting, but more then likely the plans will need to be visible.

The best approach is to make the plan visible at registration then set the plan as "Default" and exclusive. Once done add CSS to your Joomla template to hide the entire plan selection process. The user typically will never know and of course CBSubs will behave as it should.

Is there other tables than "cbsubs_subscriptions" I have to add the new user to?

If manually adding a subscription via query all you need is _cbsubs_subscriptions database table.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

13 years 9 months ago #134380 by kbotnen
Replied by kbotnen on topic Re:automatic add new users to a plan
Thank you. Worked like a charm.

Now I can make my users register themself and get placed into a subscription plan without administrator or user involvement. There is no trace of cb(subs) / acl visible for the user. Here is how i did it:

I did the cb settings as you krileon described and edited the css to hide the label, radio button and description.

To hide the radio button and plan name text:

Edit your cbpaidsubscription.css (in comprofiler/plugin/user/plug_cbpaidsubscriptions), line 4
[code:1]
.cbregPlansList .cbregPlanSelector { margin-bottom: 6px; display: none;}
[/code:1]
I added "display: none;"

To hide the label/text before the radio button (plan choices):

Same css file, line 1
[code:1]
#cbregTitle { color: red; font-size: 0; }
[/code:1]
I added "font-size: 0;"

This is for future references if anyone else need to solve the same (or a similar) problem.

This forum is nice... So is the cb + cb subs combo :)

-Kristian-

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.232 seconds

Facebook Twitter LinkedIn