Page 2 of 3

Re: Disqus Integration

Posted: Mon May 23, 2011 12:49 pm
by Josh
Thank you so much!

I will implement this on Wednesday or Thursday, when the debate on the latest blogpost is over.

Re: Disqus Integration

Posted: Sat May 28, 2011 6:49 pm
by Josh
Thank you for creating the Disqus plugin.

It still does not work for me though. I have installed the plugin, inserted my Disqus username and set the start date for this plugin to yesterday in the settings. I have even replaced by template's entries.tpl with the entries.tpl from the default theme..

When I change the theme to default theme, Disqus comment system does not show up either.

Re: Disqus Integration

Posted: Sun May 29, 2011 10:16 pm
by garvinhicking
Hi!

Do you have it currently installed? I don'T see any disqus reference on http://atlanticreview.org/archives/1479 ... urope.html - I might need to see it in action to see why it shouldn't work for you...

Regards,
Garvin

Re: Disqus Integration

Posted: Mon May 30, 2011 9:37 am
by Josh
Hi Garvin,

Yes, I have the plugin installed. When you click on comments, the permalink with a reference to disqus shows up:
http://atlanticreview.org/archives/1479 ... qus_thread

I see some disqus code in the Quelltext.

Re: Disqus Integration

Posted: Mon May 30, 2011 12:56 pm
by garvinhicking
Hi!

Can you place a {$entry.disqus} temporarily inside your entries.tpl file to see if that returns anything?

If not:

It seems, even though I don't understand why, that the plugin breaks its execution due to that line in the PHP code of the plugin file:

Code: Select all

if (!$eventData['is_extended']) return true;
this usually indicates that the extended entry is being displayed. You could try to remove that line (line 109 in serendipity_event_disqus.php) so see if you get further output then..?

Regards,
Garvin

Re: Disqus Integration

Posted: Fri Jun 10, 2011 11:19 pm
by Josh
So weird: When I wrote a new blogpost, Disqus was there and I was happy:
http://atlanticreview.org/archives/1481 ... rmany.html

Then just now I wrote yet another blogpost, but Disqus is gone again:
http://atlanticreview.org/archives/1483 ... nized.html

The only thing I changed were some settings in the S9Y comment plugin, because I was tired of moderating requests for spam comments and I wanted to disable commenting on older entries.

I fiddled with the settings, but no luck. I have also posted numerous new blogposts, but Disqus is not showing up. There is, however, a reference to Disqus in the Quelltext of the footer.

Garvin, re your advice
Can you place a {$entry.disqus} temporarily inside your entries.tpl file to see if that returns anything?
Where should I put {$entry.disqus} in the entries.tpl?

Re: Disqus Integration

Posted: Sat Jun 11, 2011 12:47 am
by Josh
Not so weird anymore.

Disqus shows up, whenever I write a blog post with an extended body. I will be fine, if they remember to always do that.

Thank you for all your help, Garvin!

Re: Disqus Integration

Posted: Wed May 23, 2012 1:47 pm
by zafiro17
I was searching for a how-to showing integration of Disqus into S9Y and came up with this thread. I want to add one final post to it just so it's clear for people wondering if Disqus and S9Y are compatible.

Answer: Yes, and it's come a long way since this thread, which seems to have needed some heavy duty coding. I simply enabled the Disqus plug in using Spartacus and input my Disqus shortname.

The Disqus stuff doesn't show up if you do a short blog post using just the "Entry Body." You also have to put some text into the "Extended Entry Body" and the Disqus stuff will add itself to your post automatically. I had Disqus up and running in under one minute. The Disqus plug in works fine, and required no tweaking at all.

Happy ending.

Re: Disqus Integration

Posted: Sun Jun 03, 2012 4:01 pm
by blog.brockha.us
Is there some technical reason why there has to be an extended part of the article for the DISQUS code to show up?

Re: Disqus Integration

Posted: Tue Jun 05, 2012 2:52 pm
by garvinhicking
blog.brockha.us wrote:Is there some technical reason why there has to be an extended part of the article for the DISQUS code to show up?
I don't remember the specific code, it could be that the form of detection if the detai page is opened uses the "extended" property in a wrong way. Generally I don't think the extended part of an entry should be required for this...

Re: Disqus Integration

Posted: Tue Jun 05, 2012 4:33 pm
by blog.brockha.us
I had a look into the code:

Code: Select all

                case 'frontend_display:html:per_entry':
                    $_ts = explode('-', $this->get_config('enable_since'));
                    $ts = mktime(0, 0, 0, $_ts[1], $_ts[2], $_ts[0]);
                    
                    if ($eventData['timestamp'] < $ts) {
                        return true;
                    }

                    $eventData['comments'] = '<a href="' . $eventData['link'] . '#disqus_thread" data-disqus-identifier="disq_id_' . $eventData['id'] . '">Disqus</a>';
                    if (!$eventData['is_extended']) return true;
I think this "if (!$eventData['is_extended']) return true;" can be deleted, because we are in the "per_entry" hook, doesn't it?

Re: Disqus Integration

Posted: Tue Jun 05, 2012 5:23 pm
by blog.brockha.us
Ah no, this is not the fix.

i fixed the problem locally but the DISQUS extension is crashing the footer designed by 2k11. So I'll check this out, too and send an update to Spartacus, when ready. :)

(The fixed version is live at my testblog at the moment. First article has no extended part, second has. Both do have the DISQUS extension)

Re: Disqus Integration

Posted: Tue Jun 05, 2012 6:12 pm
by blog.brockha.us
Okay, I think I have fixed that all.
Only one question: Why are you hiding trackbacks, too, Garvin?

Re: Disqus Integration

Posted: Wed Jun 06, 2012 8:12 pm
by garvinhicking
Great! I think 'is_extended' should have been the check to only show the disqus plugin on the extended entry page and not on the overview.
Only one question: Why are you hiding trackbacks, too, Garvin?
Because when someone is using disqus, I think he wants to maintain ALL his feedback on disqus, and not have to maintain trackbacks on the local blog.

Regards,
Garvin

Re: Disqus Integration

Posted: Wed Jun 06, 2012 9:42 pm
by blog.brockha.us
garvinhicking wrote:Great! I think 'is_extended' should have been the check to only show the disqus plugin on the extended entry page and not on the overview.
Yes, that is how I changed it..
garvinhicking wrote:Because when someone is using disqus, I think he wants to maintain ALL his feedback on disqus, and not have to maintain trackbacks on the local blog.
Huh? Disqus can handle trackbacks, too? Did you switch of the s9y trackback/pingback handling in s9y then with the plugin? I think I don't understand how this part should work..