3WC Warning in

Home Forums Jevelin Theme 3WC Warning in

Home Forums Jevelin Theme 3WC Warning in

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • CBDFactum
    Participant

    Running the W3C validator for https://cbdfactum.com generates +50 warnings like this:

    The type attribute for the style element is not needed and should be omitted.

    or

    The type attribute is unnecessary for JavaScript resources.

    <b><script type="text/javascript" data-cfasync="false"></b>

    or

    <b><script data-cfasync="false" data-pagespeed-no-defer type="text/javascript"></b>

    See also the attached result of the validation.

    I get rid of the warnings using this hook- so you won’t see currently it on the site.

    add_action( 'template_redirect', function(){
      ob_start( function( $buffer ){
      $buffer = str_replace( [ 'type="text/javascript"', "type='text/javascript'", "type='text/css'", 'type="text/css"' ], '', $buffer );
    return $buffer;
      });
    });

    I think, in one of the next updates the code could be modified so this hook is not needed and the theme generates out of the box a code without W3C warnings.

    What do you think?

    Thx

    Attachments:
    You must be logged in to view attached files.

    Hi @CBDFactum,

     

    I hope you are well today and thank you for your question.

     

    We will check how the default WordPress themes handle this situation and then will consider to change it if it doesn’t have any side effects.

     

    Also, we can only change it for the scripts generated by the theme and not the plugins.

     

    Best regards,
    Shufflehound team

Viewing 2 posts - 1 through 2 (of 2 total)

Popular choice

Professional Developers At Your Fingertips!

If you need services beyond standard support, we've got your back!

Services we offer:

Demo setup
Advanced customization
Layout adjustment
Graphic work / visualizations
Custom coding
Full WordPress development and design

Services

What we can offer

  • Demo setup +

    If you'd prefer not to handle the installation yourself or need help getting started, we'll set everything up for you.

  • Layout adjustment +

    We'll help you rearrange sections, adjust spacing, and modify the page structure to fit your needs.

  • Advanced customization +

    More complex styling changes, theme option modifications, and third-party integrations.

  • Custom coding +

    If you need something that's not included in the theme, we can code it for you.

  • Graphic work / visualizations +

    Web design services to create custom sections, pages, and blocks for your theme, plus graphics and visualizations.

  • Full WordPress development and design +

    Full website builds, custom theme development, or plugin creation from scratch.

  • About pricing +

    We'll provide a clear quote based on what you need. No hidden fees.

Professional Developers At Your Fingertips!

Custom Work Form