Header and Footer options in pages and posts

You can do this by Using template page as well as custom fields. Let us say your custom fields value are 1 and 2 for header your conditions will be. if($header==1) { get_header(1); } else {get_header();} And similarly for footer it will be if($footer==1) { get_footer(1); } else { get_footer(); }

Why are some SVG-images not visible in my footer?

Not sure if you’ve already done this, so forgive me if I’m telling you something you already know. But WordPress doesn’t support SVG Uploads out of the box, so to speak. This is due to security issues that can be created when a user uploads SVGs with malicious code. Mainly, a problem if you let … Read more

wp_footer content appearing in admin area

That’s because you’re not using add_action correctly, what you’ve written is functionally the same as this: function xyz_footer_print() { echo ‘footer script here’; } $value = xyz_footer_print(); add_action( ‘wp_footer’, $value ); xyz_footer_print() immediately runs the function and returns nothing. As a result your add_action call says that on the wp_footer even, do nothing. So you … Read more