× Joomla Facebook Connect support forum

Topic-icon JFBCInvite for any user (not just ones that are logged in via JFBC)

Active Subscriptions:

None
Hi Alex,

I am experiencing a problem with the version v3.2.2 of JFBCInvite: I can only invite someone via Facebook when I am logged into my site with a user that has registered via JFBCLogin. A user that has registered to my site via CBLogin can't invite anyone using JFBCInvite sad Also visitors to my site who have not signed up themselves can't invite anyone. Tested extensively on Firefox, Chrome, Safari, and IE.

As the modifications to improve the flow you referred to in www.sourcecoast.com/forums/topic?id=1907#p9718 haven't made it to the v3.2.2 version yet, would you be so kind to help me out with the code so I could make the modification myself?

Thank you very much!
Oliver
The topic has been locked.
Support Specialist
Oliver,
Very sorry for the delay in this. To make the Invite module always appear is pretty easy. However, as stated, it will always appear, whether the user is logged into Facebook or not. There's no way for JFBConnect to detect if the user is logged into Facebook at all, we can only detect when a user who has approved your application is visiting your site. Therefore, the code change below will show a blank Invite module (no friends) when a user isn't logged into Facebook. Please test, and if you have suggestions on how to improve what you get, definitely let us know.

In the /modules/mod_jfbcinvite/mod_jfbcinvite.php file, at line 21, simply set $fbUserId equal to true, instead of what's currently there:
$fbUserId = true

Let us know how this goes, and good luck!
The topic has been locked.
Active Subscriptions:

None
Hi Alex,

thanks for your hint. That works. I helped me out by embedding the module into an article and describe to the user that the list can be empty if not looged in to Facebook.

best regards
Oliver
The topic has been locked.
Support Specialist
Glad to hear that worked. Yes, wrapping the Invite module in an article is a great way to explain what to do!
The topic has been locked.