Your address will show here +12 34 56 78

Home Forums WP RESIDENCE – Real Estate WordPress Theme FORUM Remove Header from Certain Post Templates – Residence

This topic contains 0 replies, has 1 voice, and was last updated by  Anna 2 years, 2 months ago.

  • Author
    Posts
  • #120725

    Anna
    Keymaster

    get_header function is loading core function of wordpress. So it cannot be removed from certain php page/post templates.

    To remove header, what you need to do is write some php code into header.php

    you should create a if block like this

    if ( !is_singular('estate_property') ){

    .....

    code that you want to appear for the rest of the pages like menu and media header shoud be in there

    .....

    }

    !Make sure that inside the if you have both opening and closing statements for any div used

    Also, you may want to read the documentation for is_singular function https://codex.wordpress.org/Function_Reference/is_singular

    Thanks

You must be logged in to reply to this topic.