Home Forums Weaver Xtreme Theme JavaScript won’t work in Weaver Xtreme but will work in other theme

Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #64473
    Maureen
    Participant

    Hi Everyone!

    New website using Weaver Xtreme and Elementor for a local Chamber of Commerce: https://barringtonchamber.com/welcome-new-members/

    Chamber Master is a third-party soft-ware that helps chambers maintain and organize their member listings. I used them to create a rolling scroll of new members—something that was on the previous website.

    I dropped the html into an Elementor html widget and it did not work with Weaver X. I also dropped it into the Text edit window in WP and it did not work. I then switched back to the original theme, Dynamik Website Builder powered by Genesis Framework, and the scroll worked. I switched back to Weaver X and the scroll stopped.

    I then deactivated all the plugins, but there still was no scroll.

    Here is what the scroll should look like:

     

    And here is the html:

    <script type=”text/javascript”>
    /*<![CDATA[*/
    var _mniwq=_mniwq||[];
    _mniwq.push([“1588697260168.type”,”business_new”],[“1588697260168.display”,”text”],[“1588697260168.limit”,20],[“1588697260168.marquee”,true],[“1588697260168.scrollFreq”,35],[“1588697260168.daysBack”,360],[“1588697260168.showLinks”,true],[“1588697260168.popUp”,true],[“1588697260168.styleTemplate”,”#@id .mn-scroll-container{font-family:Arial, Helvetica, sans-serif;font-size:14px;line-height:130%;margin:8px;position:relative;height:205px;overflow:hidden}#@id .mn-scroll-item{-moz-border-radius:0;-webkit-border-radius:0;background-clip:padding-box;background-color:#2C5889;border-radius:0;color:#FFFFFF;margin:0 0 4px;position:relative}#@id .mn-scroll-item:hover{background-color:#3970AC;color:#FFFFFF}#@id .mn-scroll-name,#@id .mn-scroll-teaser{display:block;padding:5px 3px 5px 3px;position:relative}#@id .mn-scroll-link{color:inherit;text-decoration:none}#@id .mn-scroll-link:hover{text-decoration:underline}#@id .mn-scroll-slider{position:absolute;width:100%}”],[“1588697260168.create”,”mni-widgets-1588697260168″]);
    (function(b,d,a,c){b.getElementById(d)||(c=b.getElementsByTagName(a)[0],a=b.createElement(a),a.type=”text/javascript”,a.async=!0,a.src=”https://business.barringtonchamber.com/Content/Script/Widgets.js&#8221;,c.parentNode.insertBefore(a,c))})(document,”mni-widgets-script”,”script”);
    /*]]>*/
    </script>

     

    Thanks!!

     

    #64474
    scrambler
    Moderator

    Did you check the Option Allow Raw HTML and script on the page?

    There may also be some syntax issue related to Xtreme, but @weaver would have top comment on that

    #64475
    Maureen
    Participant

    Thanks Scrambler. I just checked the Allow Raw html option, but still no luck

    #64476
    Maureen
    Participant

    Here is the actual html again. Some gobbledygook was picked up when I pasted it above.

    <!– Created with Elementor –>

    <script type=”text/javascript”>
    /*<![CDATA[*/ var _mniwq=_mniwq||[]; _mniwq.push([“1588696632633.type”,”business_new”],[“1588696632633.display”,”text”],[“1588696632633.marquee”,true],[“1588696632633.scrollFreq”,35],[“1588696632633.daysBack”,30],[“1588696632633.showLinks”,true],[“1588696632633.popUp”,false],[“1588696632633.styleTemplate”,”#@id .mn-scroll-container{font-family:Arial, Helvetica, sans-serif;font-size:14px;line-height:130%;margin:8px;position:relative;height:205px;overflow:hidden}#@id .mn-scroll-item{-moz-border-radius:0;-webkit-border-radius:0;background-clip:padding-box;background-color:#2C5889;border-radius:0;color:#FFFFFF;margin:0 0 4px;position:relative}#@id .mn-scroll-item:hover{background-color:#3970AC;color:#FFFFFF}#@id .mn-scroll-name,#@id .mn-scroll-teaser{display:block;padding:5px 3px 5px 3px;position:relative}#@id .mn-scroll-link{color:inherit;text-decoration:none}#@id .mn-scroll-link:hover{text-decoration:underline}#@id .mn-scroll-slider{position:absolute;width:100%}”],[“1588696632633.create”,”mni-widgets-1588696632633″]); (function(b,d,a,c){b.getElementById(d)||(c=b.getElementsByTagName(a)[0],a=b.createElement(a),a.type=”text/javascript”,a.async=!0,a.src=”https://business.barringtonchamber.com/Content/Script/Widgets.js&#8221;,c.parentNode.insertBefore(a,c))})(document,”mni-widgets-script”,”script”); /*]]>*/
    </script>

    #64478
    scrambler
    Moderator

    To paste html or js in the forum, you need to select the text and use the preformatted format option

    #64480
    Maureen
    Participant
    <br data-rich-text-line-break="true" />/*<![CDATA[*/ var _mniwq=_mniwq||[]; _mniwq.push(["1588989269034.type","business_new"],["1588989269034.display","text"],["1588989269034.limit",20],["1588989269034.marquee",true],["1588989269034.scrollFreq",35],["1588989269034.daysBack",90],["1588989269034.showLinks",true],["1588989269034.popUp",true],["1588989269034.styleTemplate","#@id .mn-scroll-container{font-family:Arial, Helvetica, sans-serif;font-size:14px;line-height:130%;margin:8px;position:relative;height:205px;overflow:hidden}#@id .mn-scroll-item{-moz-border-radius:0;-webkit-border-radius:0;background-clip:padding-box;background-color:#2C5889;border-radius:0;color:#FFFFFF;margin:0 0 4px;position:relative}#@id .mn-scroll-item:hover{background-color:#3970AC;color:#FFFFFF}#@id .mn-scroll-name,#@id .mn-scroll-teaser{display:block;padding:5px 3px 5px 3px;position:relative}#@id .mn-scroll-link{color:inherit;text-decoration:none}#@id .mn-scroll-link:hover{text-decoration:underline}#@id .mn-scroll-slider{position:absolute;width:100%}"],["1588989269034.create","mni-widgets-1588989269034"]); (function(b,d,a,c){b.getElementById(d)||(c=b.getElementsByTagName(a)[0],a=b.createElement(a),a.type="text/javascript",a.async=!0,a.src="https://business.barringtonchamber.com/Content/Script/Widgets.js",c.parentNode.insertBefore(a,c))})(document,"mni-widgets-script","script"); /*]]>*/
    #64481
    scrambler
    Moderator

    There are a lot of errors showing up in the Web Browser console, which may indicate that something else is being broken, and that could have an effect on the script

    Go though the error and see if they give you and indication

    jquery-migrate.min.js?ver=1.4.1:2 JQMIGRATE: Migrate is installed, version 1.4.1
    (index):1 A cookie associated with a cross-site resource at http://google.com/ was set without the SameSite attribute. A future release of Microsoft Edge will only deliver cookies with cross-site requests if they are set with SameSite=None and Secure. You can review cookies in developer tools under Application>Storage>Cookies and see more details at https://www.chromestatus.com/feature/5088147346030592 and https://www.chromestatus.com/feature/5633521622188032.
    (index):1 A cookie associated with a cross-site resource at https://www.google.com/ was set without the SameSite attribute. A future release of Microsoft Edge will only deliver cookies with cross-site requests if they are set with SameSite=None and Secure. You can review cookies in developer tools under Application>Storage>Cookies and see more details at https://www.chromestatus.com/feature/5088147346030592 and https://www.chromestatus.com/feature/5633521622188032.
    16Tracking Prevention blocked access to storage for <URL>.
    (index):1 Tracking Prevention blocked access to storage for https://www.gstatic.com/recaptcha/releases/-wV2EAWEOTlEtZh4vNQtn3H1/recaptcha__en.js.
    (index):1 Tracking Prevention blocked access to storage for https://www.gstatic.com/recaptcha/releases/-wV2EAWEOTlEtZh4vNQtn3H1/recaptcha__en.js.
    (index):1 Tracking Prevention blocked access to storage for https://www.gstatic.com/recaptcha/releases/-wV2EAWEOTlEtZh4vNQtn3H1/styles__ltr.css.
    (index):1 Tracking Prevention blocked access to storage for https://www.gstatic.com/recaptcha/releases/-wV2EAWEOTlEtZh4vNQtn3H1/styles__ltr.css.
    (index):1 Tracking Prevention blocked access to storage for https://www.gstatic.com/recaptcha/releases/-wV2EAWEOTlEtZh4vNQtn3H1/recaptcha__en.js.
    (index):1 Tracking Prevention blocked access to storage for https://www.gstatic.com/recaptcha/releases/-wV2EAWEOTlEtZh4vNQtn3H1/recaptcha__en.js.
    (index):1 Tracking Prevention blocked access to storage for https://www.google.com/.
    (index):1 Tracking Prevention blocked access to storage for https://www.google.com/js/bg/BH5-EzULdXEbjM5N3xoUppNyl7SQTgG7b3UrQv9YUg0.js.
    (index):1 Tracking Prevention blocked access to storage for https://www.google.com/js/bg/BH5-EzULdXEbjM5N3xoUppNyl7SQTgG7b3UrQv9YUg0.js.
    (index):1 Tracking Prevention blocked access to storage for https://www.gstatic.com/recaptcha/api2/logo_48.png.
    (index):1 Tracking Prevention blocked access to storage for https://www.gstatic.com/recaptcha/api2/logo_48.png.
    (index):1 Tracking Prevention blocked access to storage for https://www.google.com/.
    (index):1 Tracking Prevention blocked access to storage for https://www.gstatic.com/recaptcha/releases/-wV2EAWEOTlEtZh4vNQtn3H1/recaptcha__en.js.
    (index):1 Tracking Prevention blocked access to storage for https://www.gstatic.com/recaptcha/releases/-wV2EAWEOTlEtZh4vNQtn3H1/recaptcha__en.js.
    (index):1 Tracking Prevention blocked access to storage for https://www.gstatic.com/recaptcha/releases/-wV2EAWEOTlEtZh4vNQtn3H1/styles__ltr.css.
    (index):1 Tracking Prevention blocked access to storage for https://www.gstatic.com/recaptcha/releases/-wV2EAWEOTlEtZh4vNQtn3H1/styles__ltr.css.
    business_new:1 Failed to load resource: the server responded with a status of 404 ()
    DevTools failed to load SourceMap: Could not load content for https://barringtonchamber.com/wp-content/plugins/elementor/assets/lib/swiper/swiper.min.js.map: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE

     

    Also, Is the script needed in a single page or the whole site.

    #64482
    Maureen
    Participant

    Thanks Scrambler. The script is need on one page only.

    I’ll look through the errors and see if anything stands out to me.

    #64483
    scrambler
    Moderator

    you may also want to try and remove the commented part at the beginning and end

    /*<![CDATA[*/

    /*]]>*/

    Last, you can try to insert the Script inside one of the page HTML  Insertion area, using a page custom Field, trying either the page-head-code or the postfooter  insertion area

    The reason to try both, is because some scripts are needed before the page loads, or after, so try them both (one after the other). In this case I would assume you need to use the page-head-code so try that first

    Reminder on how to create / use custom field

    https://guide.weavertheme.com/custom-fields-on-pages-and-posts-what-to-use-them-for-and-how-to-use-them/

     

    #64484
    Maureen
    Participant

    Thanks! I’ll give that a try.

    I check over the errors and didn’t see anything that would cause an issue. This is a re-design of the website, so I’ve been going back to the old theme to see what is so different that the script would work there and not in Weaver. I also put back a number of plugin the previous web dev used.

    UPDATE:  tried your suggestion about the custom fields for both page-head-code and postfooter. Neither worked.

     

     

    #64485
    scrambler
    Moderator

    Can you contact whoever provided the script?

    #64486
    Maureen
    Participant

    Yes, I’ll call on Monday.

    Thanks for your help!

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