• 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!

TOPIC: Fill form from cb_comprofiler & jos_users

Fill form from cb_comprofiler & jos_users 17 years 1 month ago #2611

  • westie
  • westie's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 3
Hi,

First post here, can someone please help me?

I have been using www.rsjoomla.com/index.php/RSform-Script...er-is-logged-in.html - which works very well and easily. However I need a single form that will call some information from jos_users such as username and email but also put some customer fields from community builder such as team manager / cb_teammanager from jos_comprofiler. I have tried using www.rsjoomla.com/index.php/RSform-How-To...ty-Builder.html#2166 but not had any luck due to my noobie php experience.

If anyone can help me that would be great as this is a pretty vital part to my site. Looking to purchase the licence once i get this working as it will be everything i need. oh and excuse any stupid comments i am infact pretty stupid.
The administrator has disabled public write access.

Re:Fill form from cb_comprofiler & jos_users 17 years 1 month ago #2644

  • westie
  • westie's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 3
Anyone? :blush:

Could really do with some pointers, sorry to be a pain...
The administrator has disabled public write access.

Re:Fill form from cb_comprofiler & jos_users 16 years 11 months ago #3199

Was wondering if you ever figured this out? I've had the same problem posted in the thread you referenced since March. I can pull the CB fields but it won't pull the lastname, firstname and e-mail. It's bugging me and my client to death. What's worse is tickets and e-mails to support have gone unanswered. The only time I've seen anyone get any help is when they accuse rsjoomla of trying to rip them off (www.rsjoomla.com/index.php/RSform-How-To...ped-me-off.html#3152).

So, now I'm going to have to post over at Joomlancers and pay someone to get this working.<br><br>Post edited by: HawkMultimedia, at: 2008/06/05 15:34
The administrator has disabled public write access.

Re:Fill form from cb_comprofiler &amp; jos_users 16 years 11 months ago #3232

K... all hail naughtyleo from Joomlancers.com for coming up with the solution (for $36).

Here's the original script:
//load the CB fields
$database->setQuery(\"SELECT * FROM #__comprofiler_fields WHERE published>0\");
$cb_fields = $database->loadObjectList();

global $my;
//cycle through the RSform fields
foreach($fields as $i=>$field){
//check if there is an equivalent field in CB
foreach($cb_fields as $j=>$cb_field){
//echo $field->name.'='.$cb_field->name.'<br />';
if('cb_'.$field->name == $cb_field->name){ //notice the additional cb_
//if we find the equivalent, we load the value
if($cb_field->table=='#__users') $key = 'id';
else $key = 'user_id';
$database->setQuery(\"SELECT {$cb_field->name} FROM {$cb_field->table} WHERE {$key} = {$my->id}\");
$fields[$i]->default_value = $database->loadResult();
}
}
}

Change:
===========
if('cb_'.$field->name == $cb_field->name){

To:
===========
if('cb_'.$field->name == $cb_field->name || $field->name == $cb_field->name){

And add {emailcloak=off} to the content item loading the form.

He said it's due to some oddity in the naming structure of CB fields. This has my form working perfectly! Thanks again, Leo!! RSJoomla! should contract you out.

Hope this helps someone else.
The administrator has disabled public write access.

Re:Fill form from cb_comprofiler &amp; jos_users 16 years 10 months ago #3278

  • westie
  • westie's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 3
Amazing! First time i heard of these joomlancers... thanks very much hawkmultimedia your a good man!
The administrator has disabled public write access.

Re:Fill form from cb_comprofiler &amp; jos_users 16 years 10 months ago #3539

I have a question on this topic posted here
The administrator has disabled public write access.
  • 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!