Forum is closed

JomSocial Fields Missing from JFBConnect Profiles Menu

JomSocial Fields Missing from JFBConnect Profiles Menu

In my JomSocial Custom Profiles, I have fields for First Name, Last Name, Gender, Country, etc..  However, when I try to maps these fields to Facebook fields in the backend using JFBConnect component under Profiles, ALL of the JomSocial Fields don't show up, so I can't map them to Facebook fields.  For example the following JomSocial fields are missing: Country and Gender.

My site is:
http://planethop.com/

I am running JFBConnect-4.3-Joomla15_20130104

http://www.sourcecoast.com/components/com_agora/img/members/13863/11012013-2149_PlanetHop-JomSocial-Custom-Profiles.png

http://www.sourcecoast.com/components/com_agora/img/members/13863/JFBConnect-JomSocial-Settings.png

planethop
useravatar
Offline
49 Posts
Active Subscriptions:

None
Administrator has disabled public posting. Please login or register in order to proceed.

Re: JomSocial Fields Missing from JFBConnect Profiles Menu

You won't normally see drop-downs or other selection type boxes in our Profile Mapping area. The reason is that Facebook's data will most likely not match up with the options you give your users. For gender, I believe Facebook uses "Male" and "Female". So, those would have to be the exact settings you'd offer your users. We're working on a better way to handle gender specifically, since it's (usually) an either or option.

As for country, if you're interested in testing a change that may work for countries, there's a minor code change you can make below. If you edit the /plugins/jfbcprofiles/jomsocial/jomsocial.php file, around line 527, you'll see the following line:

Code:

$query = 'SELECT * FROM #__community_fields WHERE type="text" OR type="textarea" OR type="date" OR type="birthdate" ORDER BY ordering';

Update that to the following (adding the --OR type="country"--)

Code:

$query = 'SELECT * FROM #__community_fields WHERE type="text" OR type="textarea" OR type="date" OR type="birthdate" OR type="country" ORDER BY ordering';

That will add the Country field to the Field Map area of JFBConnect Profiles. Then, set the correct Country field from Facebook to import into it. It's likely that the countries from Facebook will 'align' with what JomSocial allows, but there may be some countries that don't work perfectly. However, if you expect the majority of your users to come from the 'major' countries, it will hopefully work as expected. Please, please, please test and let us know how well the field gets imported and if it seems correct with the options available in JomSocial!

Some things to look for are is that Facebook (I believe) will return "United States". I don't know what JomSocial uses, but if it's U.S.A or United States of America, that would look like 2 different countries that your users may be from.

You can add "radio" or "select" to the query above and that will also show your radio or selection drop-downs (for things like Gender), but again, be aware that what imports from Facebook may not be the same as what you offer as options on your site.

Hope that helps, but if you have any questions, just let us know!

Thanks,
Alex

If you use our extensions, please consider leaving a rating and review at the Joomla! Extension Directory:
JFBConnect | SCLogin

alzander
Alex
useravatar
Offline
24055 Posts
Support Specialist
Administrator has disabled public posting. Please login or register in order to proceed.

Re: JomSocial Fields Missing from JFBConnect Profiles Menu

The country showed up with your above code changes; but when I tried to get Gender to show up, none of the JomSocial fields showed up in the backend.  I suspect it may be my code.  I tried the following two queries to also show Gender; but they did not work.  Perhaps you can provide me the correct query?
Thanks.

DID NOT WORK:
$query = 'SELECT * FROM #__community_fields WHERE type="text" OR type="textarea" OR type="date" OR type="birthdate" OR type="country" OR type=”radio” OR type=”select” ORDER BY ordering';

OR

$query = 'SELECT * FROM #__community_fields WHERE type="text" OR type="textarea" OR type="date" OR type="birthdate" OR type="country" OR type=”gender” ORDER BY ordering';

planethop
useravatar
Offline
49 Posts
Active Subscriptions:

None
Administrator has disabled public posting. Please login or register in order to proceed.

Re: JomSocial Fields Missing from JFBConnect Profiles Menu

Not sure why those don't work. Since they are "OR" statements, that shouldn't really limit the results, it should only expand them.

The only thing I notice from your post above is that the quotes around 'radio', 'select' and 'gender' is different than the quotation marks around all of the other field types. Can you check that you added normal quotation marks and not some other mark (or that your editor didn't change them to something else). Hopefully, that's all it is. SQL queries can be very picky about syntax..

Hope that helps,
Alex

If you use our extensions, please consider leaving a rating and review at the Joomla! Extension Directory:
JFBConnect | SCLogin

alzander
Alex
useravatar
Offline
24055 Posts
Support Specialist
Administrator has disabled public posting. Please login or register in order to proceed.

Re: JomSocial Fields Missing from JFBConnect Profiles Menu

Wow, good catch!  That worked.  Now I have Gender and Country being imported from Facebook to the JomSocial profile.
Thanks!!

planethop
useravatar
Offline
49 Posts
Active Subscriptions:

None
Administrator has disabled public posting. Please login or register in order to proceed.

Re: JomSocial Fields Missing from JFBConnect Profiles Menu

Awesome! Glad to hear we found the problem and very happy to hear it works now. We're revamping the profile system a bit right now. The functionality will be pretty much the same, but it will make it much easier to add new stuff in the future, which we're excited about.

Thanks for your feedback, and good luck,
Alex

If you use our extensions, please consider leaving a rating and review at the Joomla! Extension Directory:
JFBConnect | SCLogin

alzander
Alex
useravatar
Offline
24055 Posts
Support Specialist
Administrator has disabled public posting. Please login or register in order to proceed.
There are 0 guests also viewing this topic
There are 0 users also viewing this topic

Board Info

Board Stats
 
Total Topics:
11636
Total Polls:
0
Total Posts:
48886
Posts today:
7
User Info
 
Total Users:
47736
Newest User:
educarvalho2001
Members Online:
1
Guests Online:
620

Online: 
ferm
Social Stream
SourceCoast Joomla Social Extensions
Friday, 25 May 2018
JFBConnect 8.0 Coming Soon! Stay tuned.
Refer and Earn

Like our extensions? You're not alone! That's why they're used on tens of thousands of websites. Now you can earn 20% of any sale you refer to SourceCoast.com.

We provide excellent documentation, well laid out sales pages and great support. All you need to do is spread the word and we'll take care of the rest.

Learn About Our Affiliate Program