• Resolved HitByLife

    (@hitbylife)


    Hi everyone,

    Trying to port a html template to wordpress and <?php get_header(); ?> to call the header in the index.php file seems to be causing problems:

    Fatal error: Call to undefined function get_header() in /home/medopera/public_html/index.php on line 1

    How can that be??

Viewing 6 replies - 1 through 6 (of 6 total)
  • Try re-uploading the wp-includes folder from a fresh download of WordPress.

    Thread Starter HitByLife

    (@hitbylife)

    Hi esmi, thanks. I figured some of the files in the root had gone corrupt (maybe I accidentally have overwritten some files), so I just reinstalled WP. That worked. I did not loose any data or anything, it’s just a development environment.

    I’ve got the same error on englishcollective.org. Not sure if this is related, but I had just added the post_is_in_descendant_category funtion to my theme’s functions.php file. I’ve tried replacing the whole wp-include directory, but that didn’t work. I’m panicking because I don’t know what to do next. Any ideas?

    Fixed it. I put the theme’s index.php in the WordPress root accidentally, because of an ftp error on my server. Phew!

    hey dude, just simply way to remove that’s messages..
    function get_header() in <– on index.php

    open up your index.php

    u may found <?php get_header();

    add @ before get_header();

    show this code like this
    <?php @get_header();

    n u hv got blank..on that directory but your theme work

    All you’re suggesting is making the error. It needs to be fixed. get_header usually does far more than load a pretty picture for the top of the pages.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Fatal error: Call to undefined function get_header()’ is closed to new replies.