Full Post Showing Where Only A Portion Should (5 posts)

  1. backpages
    Posted 7 years ago #

    I'm creating and building a custom Theme for a client. I'm using home.php for the "main" page. I'm using page.php to display a couple of mostly static pages. Both the home.php and the page.php pull in the same sidebar.php. When the home.php pulls in the sidebar it works as it should and displays a portion of a particular post. However, when the page.php pulls in the exact same sidebar it displays the entire post, instead of just a portion of it. I'm using the <!--more--> tag in the post to control what portion should show up on the page. I don't understand why it works on the home.php page, but not on the page.php page since they are both using the exact same code via the sidebar.php page. Any help or insight would be greatly appreciated. You can see it here: http://www.redpepperinc.com/theseed . If you click on "contribute" in the top left corner you'll see the same sidebar on the Contribute page but see it's pulling in the entire post, not just the portion the Home page pulls in. Thanks for any help!

  2. Michael Fields
    Posted 7 years ago #

    Had this same problem last week. The only thing that fixed it was to call the sidebar like this in the problematic template file:

    include_once TEMPLATEPATH . '/sidebar.php';

    instead of using a template tag.

    hope this helps

  3. backpages
    Posted 7 years ago #

    Thanks mfields, I'll give it a try and let you know.

  4. backpages
    Posted 7 years ago #

    No, unfortunately, in this case that didn't make any difference. But, thanks again for the suggestion.

  5. backpages
    Posted 7 years ago #

    I'm still looking for a solution to this problem if anyone can help. Thanks!

Topic Closed

This topic has been closed to new replies.

About this Topic


No tags yet.