0

If one has a contrib module that works fine in most cases, but on a specific page (say /comment/comment) you wish it NOT to appear, but the options in Config don't give you that ability...what's the best practice for disabling functionality (in this case javascript) coming from the contrib module?

I'm using the sharebar module but it's all messed up in my comment/comment page. I tried hiding it with CSS (visibility:hidden) but can't target it no matter what I try. I even hid the html of the page itself and it still shows up! (although nothing else does)...which leads me to believe it's javascript...so how can I disable that for a particular page?

  • Sorry, but is it about JS bug or about hiding elements with CSS or what? – Mołot Mar 10 '15 at 19:31
  • It's just about the JS running on the page. I want to abort the JS being output on this particular page by the contrib module. – Sage Mar 10 '15 at 20:08
1

That seems to be a common issue with the sharebar module. The 7.x-2.x-dev version moves the sharebar into a block so that you can place it anywhere with either the block ui or the context ui.

The 7.x-2.x version is still in dev so you may need to do a little testing before enabling it on production, however, the module maintainer is suggesting that people upgrade to this version anyway.

  • Thanks for that helpful feedback. I was able to solve this issue by setting the CSS to 'display: none'. I had already tried 'visibility: hidden' which took away SOME of it, but not all. – Sage Mar 10 '15 at 21:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.