I have a sidebar that includes an excerpt of a specific page.
When viewing the index.php, the excerpt appears in the sidebar properly. When viewing a single.php post, the sidebar displays the full content of the specific page, instead of an excerpt.
I want it to always and only show an excerpt of a specific page in the sidebar. I need it to be unrelated to whether or not you’re on index.php, single.php or anything like that. How can this be done?
It’s from the correctly working sidebar which is placed inside the index.php and single.php. However when you’re viewing this sidebar.php within the single.php it shows the_content instead of the_excerpt.
I want it to always show the_excerpt. Never the_content.
If it’s the same code in all the template files, I think you’ll need to use the more tag (to create a “teaser” or edit the post in question manually by adding an excerpt for WP to use on non-index pages. The info here should clear things up http://codex.wordpress.org/Excerpt