Jump to content

Archived

This topic is now archived and is closed to further replies.

sblentlinger

Help with script that is breaking DMS

Recommended Posts

sblentlinger

Currently, we are using Freshdesk to host our support site.  We want to integrate Freshdesk chat with our main WP-DMS site, so that a client may request a live support agent through the service.  The integration they gave us was a js/jquery script before the last </body> tag on our site, the script is obnoxiously long, so I will refrain from posting it unless you want to see it.  

 

The script does not work in the DMS Scripts Header Fallback, and the only way I found to implement it was to paste it in footer.php.  However, it breaks the DMS editor and animations like iBoxes are also broken.  Do you have any recommendations?  I anticipate you will respond with using a hook.  If so, which hook do you suggest?

 

If you visit www.paylinedata.com, the script is currently integrated.  If you visit www.paylinedata.com/support, you can see the iBoxes do not animate.  

 

Thanks!

Share this post


Link to post
Share on other sites
Simon

You have the code in 3 places on that page.

Share this post


Link to post
Share on other sites
sblentlinger

That is weird.  I only added that script to the header fallback, and when it didn't work, removed it and put it in footer.php.  When I removed the script from the footer it vanished, period.  In any case, do you have any suggestions where the script should go.  I know you recommend NOT to change files in the DMS theme directory.  

 

Thanks!

Share this post


Link to post
Share on other sites
James B

I would say looking at the original post you'll need to insert this using a hook inside the body tag. I'd say use the hook wp_footer() as this is just before the closing body tag as they suggested.


Kindly search the forum and read the documentation before posting. It will help you resolve many issues.

For CSS help be sure to check out W3Schools first and be sure to download FireBug for FireFox for troubleshooting.

James B

Share this post


Link to post
Share on other sites

  • Similar Content

    • MiraAdmin
      By MiraAdmin+
      Looking for some help on a recently developed issue. Editor will not load. 
      Theme:  DMS2
      Error from:  Chrome - Inspector - console view
      Error message: Refused to execute script from 'http://xxxx.xxx/wp-content/themes/dms/dms/editor/js/gettext.js/?ver=4.9.7' because its MIME type ('text/html') is not executable, and strict MIME type checking is enabled.
      Occurs on all sites on same server. 
      WP versions to 4.9.5, 4.9.6, 4.9.7 = same behavior. Worked properly on these same versions until 07/04/2018.
      No new plugins. Isolating plugins offers same behavior. 
      Server vendor reports no changes, patches, etc. 
      Server re-starts no impact.  

      Thank you. 
    • tuciudadenred
      By tuciudadenred+
      Hi everyone, what happens is that the web page metrosalarmas.com has a google tags which I have not attacked where I can look to remove those tags and be able to locate the correct ones.
    • j powers
      By j powers+
      Looking to fond the best way to add in some javascript, the script is from Salesforce to add a chat button, ie Chat available / chat offline.  I need to add this to a specific page though.
       
      Much apprciated 
       
    • Barnaby Skinner
      By Barnaby Skinner+
      Hey team,
      Really simple question: where would I add code to a specific page header? I can see in the settings I can add code to the global header, but can't see how to do it for a single specific page. It's related to facebook pixel tracking
      Cheers
    • Dana
      By Dana+
      Hi DMS team,
      Please help out on how to add Post tags to the bottom of each post. Tried looking at the hooks tutorials but not sure what to do here.
      Thanks a lot.
       
       
       
       
×