layers_before_footer_sidebar

Since: 1.0.7 Last Updated:
Back to Main Index

Outputs your custom code after the inner footer wrapper, within the main container layout element and above the footer widgets.

Location: footer.php

Code output appears after:

Code output appears before:

The “row” div is the primary wrapper for sub-elements taking the column and span classes , and acts similar to a <ul> , in this case the footer widget columns.

before-footer-widgets

Usage

Example:

This hook is useful for inserting code into the <footer> element  that you want to conform to the chosen layout (full width or boxed), such as a full-width widget area. The following example uses layers_before_footer_sidebar  in combination with the core WordPress hook widgets_init  to register a custom widget area.

Our custom widget area gets the ID of mytheme-footerbar, which is used to define the dynamic sidebar in our custom code to output the widget in this sidebar into the footer and above the default widgets. In this example, our custom sidebar is full width and intended to take one Layers layout widget or a custom full-width widget like a newsletter signup or call-to-action banner that the user can make boxed or full width via the Footer layout options in Layers.