Support » Plugin: Insert Headers and Footers » Exclude all pages accept Home Page

  • Resolved David



    In your FAQ, it says the following:

    You can use one of the three available boolean filters: disable_ihaf, disable_ihaf_footer, disable_ihaf_header and return true value in order to disable printing either on the entire page or specifically in the header or footer of a given page.

    I want to disable the footer script on the every page accept the home page, how may I do this please as this does not make sense.

    Kind regards


Viewing 1 replies (of 1 total)
  • Plugin Author Debjit


    add_filter( 'disable_ihaf_footer', 'fn_ihaf_footer_only_home' );
    function fn_ihaf_footer_only_home() {
      if( is_home() || is_front_page() ) {
        return false;
      return true;

    Please test the above code on a staging env. before deploying to any production website.

    • This reply was modified 1 year, 7 months ago by Debjit.
Viewing 1 replies (of 1 total)
  • The topic ‘Exclude all pages accept Home Page’ is closed to new replies.