Skip to Content Skip to Menu

How to show username when registrate with invite code

  • camdri
  • camdri
  • OFFLINE
  • Posts: 35
  • Thanks: 0
  • Karma: 0
9 years 6 months ago #263432 by camdri
I'm still trying to find a solution... How can I populate a field with a Query?
I have a field called cb_sponsor and would like that to fill with he outcoume of the following query:

SELECT user_id
FROM `rv6fj_comprofiler_plugin_invites`
WHERE code = '7415da7fd0a1142d7bf539fa75ab4f80'


I tried with a Textfield and CB Query (as in tutorial) but this checks the database instead of showing a value!

How can I show the value of user_id in the field cb_sponsor?

Thanks for any help!

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

  • camdri
  • camdri
  • OFFLINE
  • Posts: 35
  • Thanks: 0
  • Karma: 0
9 years 6 months ago #263442 by camdri
IS THERE ANY WAY TO PARSE A INVITE CODE FORM THE E-MAIL TO THE REGISTRATION FORM?

UNFORTUNATELY INVITE_CODE GIVE AN ERROR ON THIS POINT.....
THERE MUST BE SOME KIND OF SOLUTION?!

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

  • krileon
  • krileon
  • ONLINE
  • Posts: 48478
  • Thanks: 8281
  • Karma: 1443
9 years 6 months ago - 9 years 6 months ago #263462 by krileon

I'm still trying to find a solution... How can I populate a field with a Query?
I have a field called cb_sponsor and would like that to fill with he outcoume of the following query:

www.joomlapolis.com/forum/153-professional-member-support/229438-how-to-show-username-when-registrate-with-invite-code?limitstart=0#262960

Replace u.`username` with u.`id`.

IS THERE ANY WAY TO PARSE A INVITE CODE FORM THE E-MAIL TO THE REGISTRATION FORM?

I've already answered that question. See my previous replies. The only way is to try and use CB Query Field, but as I've already told you it probably won't work.


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: 9 years 6 months ago by krileon.

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

  • camdri
  • camdri
  • OFFLINE
  • Posts: 35
  • Thanks: 0
  • Karma: 0
9 years 6 months ago - 9 years 6 months ago #263483 by camdri
You're right. It doesn't work. Is there maybe a way to read out the current URL? Because the invite code is part of that link and I could trim that.

When I poulate the SQL line with the invite code as a hard string like '25951ecbe58660ea1cfdb8a7b3c9ece8' it works fine. '[invite_code]' is empty indeed.
But the question is maybe also if I can read out the invite code field in the form (rather than the database field) which is already present. See the file...

Would be a bummer if this wouldn't work someway or the other...

thanks anyway!
Attachments:
Last edit: 9 years 6 months ago by camdri.

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

  • krileon
  • krileon
  • ONLINE
  • Posts: 48478
  • Thanks: 8281
  • Karma: 1443
9 years 6 months ago #263548 by krileon
No, CB Query Field does not parse GET for substitutions. CB Auto Actions is the only plugin with that behavior as it's needed depending on the trigger. What you're wanting requires modifying CB Invites or developing a new fieldtype plugin to output what you want. As there is no user existing yet there's no user to substitute from so it requires a custom solution.


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.

  • camdri
  • camdri
  • OFFLINE
  • Posts: 35
  • Thanks: 0
  • Karma: 0
9 years 6 months ago #263628 by camdri
OK Thanks. Have to leave it as it is...

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

Moderators: beatnantkrileon
Powered by Kunena Forum