Disqus not working because you add _td to my div

Posted in: Newsmag
Post count: 115

Hi.

We try to use Disqus on our site, but have found out that you change the div id in the DOM.

It gets _td in the name, and then Disqus dont work

I have made a temporary fix, but why do you put _td to my own divs in the DOM ?

/Jens

Post count: 1291

Hi,

I’ve tested Disqus and it works fine on my side, please provide more details about your issue.

Thank you!

Post count: 115

Your javascript adds _td to the <div id=”disqus_thread”> so the ID becomes disqus_thread_td.

I have made a workaround, but why do you alter none-newsmag ID´s

It’s in line 1501 in the js file

/Jens

Post count: 1291

Hi,

I;ve checked it on my side and the theme code doesn’t interfere with disqus – http://screencast.com/t/wtfEdgaT – on line 1501 there’s nothing on my side – http://screencast.com/t/SyMJSwE2

Please check if the js comes from the theme or another plugin. Or provide more details so i can replicate this issue on my side.

Thank you!

Post count: 115

Have you smooth scrooll enabled.

Here’s the code in you js file (tagdiv_theme.js)

It happends when you link to the /#disqus_thread from frontpage to article 🙂

/**
* if we have link.php#hash we search the document for elements with that name or id so we can rename them to avoid the default screen scrolling
*/
if ( document.location.hash) {
if( jQuery(document.location.hash).length != 0 ) { //we have elements that match the id

//prepare a new name for the hash
var new_target_hash = window.location.hash.substring(1) + ‘_td’;

//get the target element
td_hash_scroll_to_dom_element = jQuery(document.location.hash);

//change the element id
td_hash_scroll_to_dom_element.attr(“id”, new_target_hash);

//scroll to element
td_util.scroll_into_view(td_hash_scroll_to_dom_element);

/*
// do not rename the hash back! bug in firefox after comment submition + an enter in the nav bar
setTimeout(function(){
//put the hash back after the rename
td_hash_scroll_to_dom_element.attr(“id”, window.location.hash.substring(1));
}, 2000);
*/

}

Post count: 6600

Hi,

That part doesn’t refer to the disqus plugin but it’s possible to interfere with it.
I’ll add this on our todo list for further testing and if we find something wrong in this regard we will fix this in the next theme updates.

Sorry for the inconvenience!
Thanks for the message!

Post count: 115

Hey.

It’s interfering.

Look at this

You have changed the normal disqus_thread code to disqus_thread_td in the dom.

I can fix it myself, but I think you should only change your own doms / id not 3’rd part 🙂

btw: the issues is worse in 2.1 since you now also does it allthough smoothscroll is disabled !

Post count: 208

I just installed Disqus on my website with no issues with it at all. I did not even have to change any code. Smoothscroll is on too. http://www.awesomebryner.com

Post count: 208

Nevermind, I just tried without being logged into my website and comments aren’t showing.

Post count: 208

Another nevermind. I uninstalled the Disqus comments, since I don’t have a lot of comments on my site and I don’t want to deal with these comments not showing issues. So I am sticking with WordPress comments.

Post count: 208

I just got back from my sister coming to take me and our mother out to lunch to Golden Corral. I deactivated WordPress Zero Spam plugin that I was using for WordPress comments and reinstalled Disqus and my comment boxes were there for non members. So it was that WordPress Zero Spam, was my problem. I don’t need it for Disqus spam, because it has its own filters for spam comments.

That was nice and easy fix. So I will stay with Disqus, now that it works fine. Anyways, good luck with your situation Jens H. and sorry for hijacking your thread.

Post count: 6600

@doucare1971,
Glad you’ve sorted it out eventually!


@Jens
H.
I’ve just added this on our issue tracker list, we will review your report and make the necessary changes in the next theme versions.

Thanks for the message!

Post count: 115

Please do.

thank you.

/Jens

Viewing 13 posts - 1 through 13 (of 13 total)
You must be logged in to reply to this topic.