• Hi,
    I am creating a blog with WordPress. The blog has completely different layout from static page’s. Meaning that even the header and footer are different.
    Therefore I moved the header and footer code into page.php, and remove <?php get_header(); ?> <?php get_footer(); ?>.
    Until here everything works fine …. except …. in the <div class=”entry”> where the text of the post should be shown, only the 1st character of the 1st word is shown.
    When I roll back and use <?php get_header(); ?> <?php get_footer(); ?> the text of the post is showing fine.
    What am I missing??????

Viewing 2 replies - 1 through 2 (of 2 total)
  • Try this approach. Take the header and footer code out of page.php. Change header.php to

    <?php
    if ( is_home() ) {  // blog page
      include (TEMPLATEPATH . '/header_blog.php');
    } else {
      include (TEMPLATEPATH . '/header_static.php');
    }
    ?>

    Create the two files header_blog.php and header_static.php. Put the appropriate header code in each file.

    Use the same technique for footer.php

    Thread Starter bign

    (@bign)

    Thanks, I like this approach.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘WordPress page.php customization’ is closed to new replies.