Skip to Content Skip to Menu

🌟 CB Editor Assistant 1.0.0 is here! Discover our new AI Joomla Plugin that wrote its story! (and this banner!)
Start at just $12.50/month* or 💸 save 30% with our 🛍️ Intro Black Friday Offer for a lifetime*

Monthly Model using CB Content Module Time Function

  • fede312
  • fede312
  • OFFLINE
  • Posts: 166
  • Thanks: 28
  • Karma: 1
5 years 2 months ago #314462 by fede312
Using the CB Content module for releasing articles once a week in a monthly subscription.

Setup:
Every month subscribers will get a new ACL permission.
That permission will give them access to 4 new articles.

What is the right way to setup the CB Content Module to release the articles once a week?

For Example:
If I set up 4 modules, one for each week of that month.

CB Content Module 1: on the Timed tab
Start: 1/1/18 - End 1/8/18 - Repeat: Monthly
Before: Empty - During: (New Article 1) - After: Empty

CB Content Module 2: on the Timed tab
Start: 1/8/18 - End 1/15/18 - Repeat: Monthly
Before: Empty - During: (New Article 2) - After: Empty

CB Content Module 3: on the Tab Timed.
Start: 1/15/18 - End 1/22/18 - Repeat: Monthly
Before: Empty - During: (New Article 3) - After Empty

CB Content Module 4: on the Tab Timed.
Start: 1/22/18 - End 1/30/18 - Repeat: Monthly
Before: Empty - During: (New Article 4) - After: (Copy of New Article 4)

A member that subscribed the 1st week of the month will see:

Week 1: Article 1.
Week 2: Article 1, Article 2.
Week 3: Article 1, Article 2, Article 3.
Week 4: Article 1, Article 2, Article 3, Article 4.

But a subscriber that subscribed the 4th week will see:

Week 1: Article 1, Article 2, Article 3, Article 4.
Week 2: Article 1.
Week 3: Article 1, Article 2.
Week 4: Article 1, Article 2, Article 3.

How do I get around this?
I'm not sure if the before and after content can work around this solution. It doesn't have to be perfect, the idea is to give the subscriber a sense of motion.

Thanks,

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48551
  • Thanks: 8291
  • Karma: 1445
5 years 1 month ago #314470 by krileon
The CB Content Module timed content feature has nothing to do with Joomla articles. It just allows scheduling the module to show/hide based off a configured timetable. It has no interaction with CBSubs either. For what you're wanting to do you should use the built in CBSubs content prepare usage shown below.

www.joomlapolis.com/news/18550-cbsubs-gpl-4-1-with-timed-content-taxes-inclusive-price-display-and-plan-substitutions-usable-anywhere

You'd basically wrap the articles contents in CBSubs substitutions to time when the contents should be visible based off their subscription.


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 or Create an account to join the conversation.

  • fede312
  • fede312
  • OFFLINE
  • Posts: 166
  • Thanks: 28
  • Karma: 1
5 years 1 month ago - 5 years 1 month ago #314482 by fede312
I called them Articles for lack of a better name, actually I'm using videos.
If I follow that method what happens when the subscriber cancels the subscription and renews a few months later?

Let's say the member subscribes Jan 1, 2019. Provided I write the proper code the member will get a new video each week. Week 1 (Video 1). Week 2 (Video 2). Week 3 (Video 3). Week 4 (Video 4).

What happens if the member cancels at the end of the month and then he renews 3 months later? Let's say on April 1, 2019.

Will the subscription continue from Week 5?
Will the subscription reset and start again from Week 1?
Or Will the subscription continue from week 13?
Last edit: 5 years 1 month ago by fede312.

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48551
  • Thanks: 8291
  • Karma: 1445
5 years 1 month ago #314496 by krileon

If I follow that method what happens when the subscriber cancels the subscription and renews a few months later?

If they cancel then they'll lose access. The timed feature provided by CBSubs is based off how long they've been subscribed, expired, etc.. depending on how you've setup the IF condition.

What happens if the member cancels at the end of the month and then he renews 3 months later? Let's say on April 1, 2019.

It should resume as normally since by default the IF substitutions condition off the subscription date unless you tell it to condition off a different date. Example as follows.

Subscription Date: 08/15/2019 10:36:52
Last Renewal Date: 08/15/2019 10:36:52

With the above I've no cancelled my subscription. I've now lost access to the content. Now I'll renew the subscription and have the following.

Subscription Date: 08/15/2019 10:36:52
Last Renewal Date: 09/30/2019 09:15:42

Notice the subscription date remains the same. This means their timed content should resume normally.


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 or Create an account to join the conversation.

  • fede312
  • fede312
  • OFFLINE
  • Posts: 166
  • Thanks: 28
  • Karma: 1
5 years 1 month ago - 5 years 1 month ago #314515 by fede312

Notice the subscription date remains the same. This means their timed content should resume normally.


That doesn't work for me, because if I subscribe for only a month, cancel and then renew at the end of the year. I will have access to all of the one year material.

I guess we have two different models in mind. You are talking about a software company model:

Subscriber pays. Subscriber gets access. (ACL Access ON)
Subscriber cancels. Subscriber loses access. (ACL Access OFF)
Subscriber renews. Subscriber gets access back. (ACL Access ON)

In which case this is fine.

I'm talking about a school or a course model. In which every month is assigned to a specific numbers of lessons using multiple ACL Permissions (month 1, 2, 3, 4, etc) and they are unlimited.

Subscriber Pays. Subscriber gets [month 1] access.
Subscriber Cancels: Subscriber keeps [month 1] access.
Subscriber Renews: Subscriber gets [month 2] access.
Subscription Expires: Subscriber keeps [month 2] access.

What I'd like to be able to do, is to drip the 4 lessons contained on each monthly permission and release them on a weekly basis instead. To promote activity and a sense of continuity.
Last edit: 5 years 1 month ago by fede312.

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48551
  • Thanks: 8291
  • Karma: 1445
5 years 1 month ago #314522 by krileon
CBSubs IF substitutions support the same elseif and else usages that normal CB IF substitutions do. You can condition off subscription date, last renewal date, expiry date, and/or previous expiry date. Based off what you're needing you're going to have to condition off subscription date AND last renewal date to try and deal with your timeframes.

What I'd like to be able to do, is to drip the 4 lessons contained on each monthly permission and release them on a weekly basis instead. To promote activity and a sense of continuity.

You don't need timed content at all then. You just need a counter that increments with each renewal then condition against that counter. Easiest way to do that is just use a CB Query Field to query for how many times they've renewed and condition against it with a normal CB IF substitution. The below query should work fine for giving you accurate counter.

Code:
SELECT ( `regular_recurrings_used` + 1 ) FROM `jos_cbsubs_subscriptions` WHERE `user_id` = '[user_id]' AND `plan_id` = PLAN_ID_HERE

Notice the +1 since the recurrings used starts at 0. This ensure it counts the initial subscription. This query isn't checking subscription state so whether they're expired or active it still accurately counts how many times they subscribed to the supplied plan id.


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 or Create an account to join the conversation.

Moderators: beatnantkrileon
Powered by Kunena Forum