• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer
Logo

CITROWEB

First choice for your online presence

  • home page
  • Services
    • Web design, web development and consulting
    • Online stores with WooCommerce
    • Technical support for WooCommerce stores
    • Search engine marketing
      • SEO: Your website receives more relevant visitors
      • SEA: Search engine advertising for your website
    • Web hosting packages and domains
  • Blog
  • Contact us
Home » Blog » Remove wrap DIVs (.wrap) in Genesis

Remove wrap DIVs (.wrap) in Genesis

22. December 2021

.wrap DIVs in DOM

Genesis inserts .wrap DIVs in all HTML elements of the page to enable center alignment, for example.

It is recommended to reduce the DOM depth to improve the hygiene factors of a page. If you don’t need the .wrap DIVs, there is potential here to reduce the DOM depth. The wrapper DIVs (.wrap) can be easily removed programmatically.

To remove the .wrap DIVs from all page elements, the following code is needed:

remove_theme_support( 'genesis-structural-wraps' );

To remove the .wrap DIVs for all elements except for the header, the code looks like this:

add_theme_support( 'genesis-structural-wraps', array( 'header' ) );

You can find an overview of all elements here.

Filed Under: development, Genesis Framework

Primary Sidebar

Search

Recent Posts

  • Remove “Thank you for your trust in WordPress” from the bottom of the dashboard
  • Remove WordPress logo from toolbar
  • Change login cookie lifetime in WordPress
  • WordPress multisite and cookie settings in wp-config.php
  • Update GUIDs in WordPress after domain move

Footer

Logo




© 2023 CITROWEB
  • Data protection
  • imprint
  • Deutsch