Topic-icon Login Graph Tag Not Working

Active Subscriptions:

None
14 years 3 months ago #19385 by trawel
Alex,

In a previous post you helped me by showing me a code modification which prevents the comments box from being displayed below articles if the user isn't logged in. Here's that code:

if ($user->guest)
return "There are comments. You must be registered and logged in to comment.";
else
return $commentString;

I then appended the {JFBCLogin} tag to display the login button as show in this photo.

File Attachment:
.

After moving from my DEV environment to my PROD the login button is not working. It only shows the raw tag and won't display the button. Here's how it looks:

There are 0 comments. You must be registered and logged in to comment.
{JFBCLogin size=medium logout=true key=xxxx}

I'm able to get the button to show elsewhere on my site using the {JFBCLogin} tag. Any thoughts as to why the tag is now not being displayed when I add it to the line of code you provided? I'd really like a login button below that message.

Thanks again for your help.
Tracy
The topic has been locked.
Support Specialist
14 years 3 months ago #19412 by alzander
Tracy,
Can't say I know exactly the cause, but it's likely an ordering issue between the JFBConnect Content and System plugins. Can you try making the Content plugin ordered at the highest of it's group (position 0) and the System plugin at the end of it's group (highest number). Then, if that doesn't work, swap those and see if that helps.

In all attempts, please try disabling Global Configuration and the System - Cache plugin, if enabled, so that they don't mask your results.

Hope that helps, but let us know if you still need help.

Thanks,
Alex
The topic has been locked.
Active Subscriptions:

None
14 years 3 months ago #19445 by trawel
Replied by trawel on topic Login Graph Tag Not Working
Hi Alex,

I tried swapping the order of both the system and content plugins. I also ensured that caching in the global configuration and the system cache plugin was disabled. Unfortunately it's still showing the tags.

I would be glad to give you a login to the admin section. I tried to send you a private message but had a difficult time finding your name in the list of users. If you could send me one I'll reply with a user name and password.

Thanks
Tracy
The topic has been locked.
Active Subscriptions:

None
14 years 3 months ago #19447 by mtk
Replied by mtk on topic Login Graph Tag Not Working

trawel wrote: Hi Alex,

I tried swapping the order of both the system and content plugins. I also ensured that caching in the global configuration and the system cache plugin was disabled. Unfortunately it's still showing the tags.

I would be glad to give you a login to the admin section. I tried to send you a private message but had a difficult time finding your name in the list of users. If you could send me one I'll reply with a user name and password.

Thanks
Tracy

Hello Tracy,
I'm just curious about something: if you undo the above hack (and restore the plugin to its default state) are the tags converted into their corresponding code?

as for sending PMs, please send them to me (not Alex).
to the left of this message/post you can find an arrow (under my posts counter) and there you'll find the option to directly send me a PM.

Mati
The topic has been locked.
Active Subscriptions:

None
14 years 3 months ago #19454 by trawel
Replied by trawel on topic Login Graph Tag Not Working
Hi Mati,

No luck removing the hack, but I should say that if I remove the hack I have no need to have a login button as the comment box will always display. This did work at one time I just can't isolate what setting I had right in my DEV environment but not in my PROD. I'll send you the user name and password to log into the site backend now.

Thanks!
Tracy
The topic has been locked.
Active Subscriptions:

None
14 years 3 months ago #19455 by mtk
Replied by mtk on topic Login Graph Tag Not Working
could you please send my a page where I can see the problem (where you put the TAG that are not parsed)?
The topic has been locked.
Active Subscriptions:

None
14 years 3 months ago #19456 by trawel
Replied by trawel on topic Login Graph Tag Not Working
Sure, here you go:

www.lincolnspeak.com/street-talk/57-title-tester

Make sure you are logged out of the front end. It will only show for guests based on the code Alex provided for me.
The topic has been locked.
Active Subscriptions:

None
14 years 3 months ago #19457 by mtk
Replied by mtk on topic Login Graph Tag Not Working

trawel wrote: Sure, here you go:

www.lincolnspeak.com/street-talk/57-title-tester

Make sure you are logged out of the front end. It will only show for guests based on the code Alex provided for me.

could you please explain to me, where are those TAGs posted?
I cannot find them in the modules or the content items.
The topic has been locked.
Active Subscriptions:

None
14 years 3 months ago #19459 by trawel
Replied by trawel on topic Login Graph Tag Not Working
Per Alex's directions I placed it in the following location;

/plugins/system/jfbcsystem/jfbcsystem.php file. Around line 671

So the code in that file right now looks like this:

if ($user->guest)
return "<p><hr />There are <fb:comments-count href=".$href."></fb:comments-count> comments. You must be registered and logged in to comment.<p>{JFBCLogin size=medium logout=true key=xxxx}";
else
return $commentString;

I was wondering if maybe I'm not including the tag correctly.
The topic has been locked.
Active Subscriptions:

None
14 years 3 months ago #19460 by mtk
Replied by mtk on topic Login Graph Tag Not Working

trawel wrote: Per Alex's directions I placed it in the following location;

/plugins/system/jfbcsystem/jfbcsystem.php file. Around line 671

So the code in that file right now looks like this:

if ($user->guest)
return "<p><hr />There are <fb:comments-count href="/.$href."></fb:comments-count> comments. You must be registered and logged in to comment.<p>{JFBCLogin size=medium logout=true key=xxxx}";
else
return $commentString;

I was wondering if maybe I'm not including the tag correctly.

well, since Joomla Plugins only parse one layer of tags, the {JFBComment} is parsed into the code you just wrote, but the second layer of TAGs is left unparsed.
simple replace the:
{JFBCLogin size=medium logout=true key=xxxx}
with a code the plugin doesn't have to parse:
<fb:login-button v="2" size="medium" scope="email,publish_stream,user_about_me,user_status" onlogin="javascript:jfbc.login.login_button_click();">Login With Facebook</fb:login-button>
The topic has been locked.