• Resolved grantdb

    (@sixer)


    Just wondering if the plugin outputs this:
    <script type='text/javascript' src='https://cdn.grantdb.ca/wp-content/cache/caos-analytics/analytics.js?ver=5.5' id='caos-async-analytics-js-js'></script>

    I am getting a warning from W3C HTML Validator:

    Warning: The type attribute is unnecessary for JavaScript resources.
    
    From line 21, column 9323; to line 21, column 9469
    
    endif]--> <script   type='text/javascript' src='https://cdn.grantdb.ca/wp-content/cache/caos-analytics/analytics.js?ver=5.5' id='caos-async-analytics-js-js'></script>

    Just wondering if this plugin might need a little update to change this output?
    Thank you for such an amazing plugin!

    • This topic was modified 4 years, 7 months ago by grantdb.
Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author DaanvandenBergh

    (@daanvandenbergh)

    Hmmm, I’ll have to check.

    The analytics.js is enqueued using WP’s script enqueuing system (wp_enqueue_scripts()) so I think WordPress is generating this line, but I’ll check later today! Thanks for notifying me!

    Plugin Author DaanvandenBergh

    (@daanvandenbergh)

    Hi again,

    I just tested it and in my testing environment (and other production environments) the code is output like this:

    Asynchronous Snippet Type:
    <script async src="https://daan.local/wp-content/uploads/caos/analytics.js" id="caos-async-analytics-js"></script>

    Default Snippet Type:
    <script src="https://daan.local/wp-content/uploads/caos/analytics.js" id="caos-analytics-js"></script>

    So, I’m afraid another plugin is modifying your HTML output.

    If you could make a list of the plugin’s you’re using I might be able to help you make an educated guess?

    Thread Starter grantdb

    (@sixer)

    Thank you for your testing and response. I haven’t been able to find the plugin, however I am narrowing down to the culprit. Will update this post with my findings asap.
    Cheers!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘The type attribute is unnecessary for JavaScript resources’ is closed to new replies.