Skip to Content Skip to Menu

🎃 Happy Halloween! Treat yourself with an awesome discount on memberships! Get 20% off now with code SPOOKY-2024!

cbsubs payment page

  • inet2800
  • inet2800
  • OFFLINE
  • Posts: 19
  • Thanks: 0
  • Karma: 0
10 years 11 months ago #237128 by inet2800
cbsubs payment page was created by inet2800
I'm using CB Subs and this is my scenario:

1st step) User fills out the registration form
2nd step) User is redirect to the payment page (Authorize.net)
3rd step) User pays

I have a custom payment form that I developed using the rounded template plugin and
I want to show the Username on step 2.

- I tried by getting the Joomla user object but I understand that doesn't work because I'm not logged in yet.

Is there any other way to get the username info on the payment page?

Best Regards,
Lucas

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

  • krileon
  • krileon
  • ONLINE
  • Posts: 48473
  • Thanks: 8281
  • Karma: 1443
10 years 11 months ago - 10 years 11 months ago #237175 by krileon
Replied by krileon on topic cbsubs payment page
No idea what changes you've made, but the below can build the current users object and give you access to all of the CB user object variables such as the username.

Code:
$user = CBuser::getMyUserDataInstance() $username = $user->username;

This isn't going to do anything if the user isn't logged in though. So for registration your chances of getting this info are basically slim to none. I've no idea if the template files have access to any variables outside of themselves. If they do just try accessing $user and see if that works.


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.
Last edit: 10 years 11 months ago by krileon.
The following user(s) said Thank You: inet2800

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

Moderators: beatnantkrileon
Powered by Kunena Forum