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 🛍️ Black Friday Intro Offer for your subscription's lifetime
🎉 Black Friday sale is here! Great savings on professional and developer memberships! Get 25% off now with code BLACK-FRIDAY-2024!

collect a cb field in php

  • moomola
  • moomola
  • OFFLINE
  • Posts: 37
  • Thanks: 0
  • Karma: 0
12 years 1 month ago #212436 by moomola
collect a cb field in php was created by moomola
Hello,

anyone knows the best way to get and store a cb field into a
php variable into a php script ?

Thanks

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

  • anydaytv
  • anydaytv
  • OFFLINE
  • Posts: 2
  • Thanks: 1
  • Karma: 0
12 years 1 month ago #212441 by anydaytv
Replied by anydaytv on topic Re: collect a cb field in php
Community builder probably has an api for it and maybe someone more knowledgeable than me will help, but...

The easiest way to do this is to grab the joomla user-id and then query the database for the information.

You can get the userid with the following code:
$user = JFactory::getUser(); $userId = $user->id;

Now just query the database using the userid to grab the info you want.
The following user(s) said Thank You: moomola

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

Moderators: beatnantkrileon
Powered by Kunena Forum