Skip to Content Skip to Menu

CB Library API Documentation

7 years 5 months ago #294104 by RoagoChrisB
CB Library API Documentation was created by RoagoChrisB
Hello. I've been working with CB 2.0 for a while now and have come to the point where I need to override modules to fit the look I'm going for. In this particular case, I'm wanting to change the mod_cblogin module to display Login and Register links (that take the user to the CB login and register pages) with no fields. I went ahead and overrode the mod_cblogin in the template I'm using and made a couple of new login/logout php files for my changes. Looking through the code to see how you accomplished linking to Register in the default horizontal PHP file, I see the url is obtained from:

<a href="<?php echo $_CB_framework->viewUrl( 'registers', true, null, 'html', $secureForm ); ?>"<?php echo ( $styleRegister ? ' class="' . htmlspecialchars( $styleRegister ) . '"' : null ); ?>>

I looked for information on the $_CB_framework object in both the primer and the online documentation, but I couldn't find anything. Is there somewhere I can go to find a reference to the CB API so I know what the functions and their parameters do?

Thanks,
Chris

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

  • krileon
  • krileon
  • ONLINE
  • Posts: 48449
  • Thanks: 8280
  • Karma: 1443
7 years 5 months ago #294116 by krileon
Replied by krileon on topic CB Library API Documentation
We've the below documentation in addition to the manual.

www.joomlapolis.com/documentation/127-community-builder

Additionally we've the below videos.

www.youtube.com/playlist?list=PLp0puRITgC7PuyzPsMUECDI46VE7IFSAX

Most of it is usage documentation and not API documentation. We do not currently have a full API documentation of any sort. However most/all of our code has phpdoc and the best way to utilize the API is to load your Joomla install into phpstorm and let the auto complete help. However $_CB_framework is a global established in the module before the layout loads so you don't need to do anything further to that usage to output the registration URL.

I'm not sure what you mean by take them to the registration and login pages with no fields.


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.
The following user(s) said Thank You: RoagoChrisB

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

7 years 5 months ago #294134 by RoagoChrisB
Replied by RoagoChrisB on topic CB Library API Documentation
Thanks for the links!

What I meant by taking the user to the registration or login page was that the cblogin module would just be text links instead of having the username/password/secret_key fields displayed as well. Those would be on the actual login page. Then, when the user logs in, the links would be replaced by something like their user avatar and a logout button. But I should be able to make that happen with the information you provided.

Thanks,
Chris

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

  • krileon
  • krileon
  • ONLINE
  • Posts: 48449
  • Thanks: 8280
  • Karma: 1443
7 years 5 months ago #294150 by krileon
Replied by krileon on topic CB Library API Documentation
Registration isn't accessible for logged in users. The login module already automatically changes to a logout module when logged in. So still not entirely sure what you're trying to do exactly.


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