Please Log in or Create an account to join the conversation.
You should be able to just use CBSubs content plugin functionality for that. Anywhere Joomla content plugins are supported you can use the following substitution usages.Is there API documentation of CB / CB Add-Ons? Integrating code would be much easier with this.
I wrote the following to get the user's expiration date. Is this the correct way to go about it?
Please Log in or Create an account to join the conversation.
I tried adding that to the end of the auto action URL in a new tab; it still generated the card for my own user. It might be because I access user via CBuser::getMyUserDataInstance() .To have it render specific users other than yourself be sure to add &users=[user_id] when using this in a Custom HTML field or anywhere that supports substitutions.
You should be able to just use CBSubs content plugin functionality for that. Anywhere Joomla content plugins are supported you can use the following substitution usages.
[cbsubs:subscriptions plan="PLAN_ID_HERE" output="expiry_date" /]
Please Log in or Create an account to join the conversation.
I assume you're outputting the URL in a new tab via a Custom HTML field? The below is an example of what the URL should look like in a Custom HTML field.I tried adding that to the end of the auto action URL in a new tab; it still generated the card for my own user. It might be because I access user via CBuser::getMyUserDataInstance() .
CB Auto Actions supports substitutions and content plugins directly inside of it. Simply turn content plugins on under Parameters and that usage will work in your code that's responsible for generating your image. Just be sure to always treat substitutions and content plugin responses as strings. Example as follows would work.I don't think that would work for me. I need the subscription expiration date generated in PHP onto the card image. The user might have multiple subscriptions, with only one being active; the function I wrote above was able to figure out which arbitrary subscription has the longest expiration date. It works great, just thought it was a bit tricky figuring out where this data was tucked away.
Please Log in or Create an account to join the conversation.