Featured Pages Widget: "After Content" Error
-
Hello,
I’m currently using the below code snippet so I can add recent posts as well as custom content to my home page. I would like to include custom content before my recent posts. When I set it the hook to “after_header,” the custom content appears as a full-width page and excludes my sidebar. If I set it “before_content,” the content displays before every single one of my recent posts.
Is there any way to set it so I can have custom content before my recent posts but still integrate the content according to the default layout (right sidebar)?
My site is https://passportandplates.com
Thanks in advance for your help!
CODE:
add_filter( ‘tc_default_widgets’ , ‘add_featured_page_widget’ );
function add_featured_page_widget( $defaults ) {
$defaults[‘fp_widgets’] = array(
‘name’ => __( ‘Featured Pages Widget’ , ‘customizr’ ),
‘description’ => __( ‘Above the featured pages area on home’ , ‘customizr’ )
);
return $defaults;
}add_action(‘__after_header’ , ‘display_my_fp_widget’);
function display_my_fp_widget() {
dynamic_sidebar(‘fp_widgets’);
}
- The topic ‘Featured Pages Widget: "After Content" Error’ is closed to new replies.