Jump to content
Sign in to follow this  
nrbeatty

Excerpts- Spacing and/or Customization (WHP)

Recommended Posts

catrina    103
catrina

I don't see any run-on text. It looks fine to me. Which browser are you viewing the site on? (I'm viewing on the latest Firefox for Mac)


Please read the docs before posting. Please do not private message me unless I ask you to.

Designer | Catrina Dulay

Founder | Catrina and Mouse

Share this post


Link to post
Share on other sites
nrbeatty    0
nrbeatty

I'm using the latest FF and Safari. Check out screenshots: http://imgur.com/a/eJWIR The top image is the single-post page, with proper spacing. The second image is from the blog/posts page. Do you see how the excerpt loses all spacing? 1) Does the excerpt understand hard line-spacing? 2) What about custom excerpts for WHP?

Share this post


Link to post
Share on other sites
timlinson    3
timlinson

Wordpress strips the formatting from excerpts. There are probably excerpt plugins for more customized excerpts, or you could try something like this.

Share this post


Link to post
Share on other sites
nrbeatty    0
nrbeatty

Thanks Tim. I'll check out plug-ins. I thought customizing excerpts was old news- why do I recall lots of themes having a box or short-code for that, and maybe I'm wrong, but I thought wordpress even supported custom excerpts. Am I crazy?

Share this post


Link to post
Share on other sites
Kate    3
Kate

Hey Nick, You can use the "Custom Excerpt" box underneath the post edit screen. If you don't want to do that each time, then you would modify the post loop file, perhaps adding code for a plugin like "The Advanced Excerpt". (The line of code used for the plugin would basically take the place of the current code.)

Share this post


Link to post
Share on other sites
nrbeatty    0
nrbeatty

I see now- the "Excerpt" field was switched off by default in WP 3.1. When using custom excerpt, I need to add the "Read More" code to the functions.php file, so I don't have to add the one-line of code to each custom excerpt. How can I add it to the custom code box for WhiteHousePro? Here is the code that should go in functions.php file; I want to put in the the custom code box- what do I need to add to get that to work from the custom code box?

function excerpt_read_more_link($output) {
	 global $post;
	 return $output . 'ID) . '"> Read More...';
	}
	add_filter('the_excerpt', 'excerpt_read_more_link');[/code]

Thanks! Nick

Share this post


Link to post
Share on other sites
catrina    103
catrina

The Custom Code CSS rules box can only have CSS. It can't have PHP inside it. WhiteHousePro also has a functions.php file...


Please read the docs before posting. Please do not private message me unless I ask you to.

Designer | Catrina Dulay

Founder | Catrina and Mouse

Share this post


Link to post
Share on other sites
nrbeatty    0
nrbeatty

Thanks for the clarification. I was just trying not to edit edit files that might be reset with theme updates. I added the code above to the functions.php file. It "kills" the website and the broswer displays:

Parse error: syntax error, unexpected '"' in /home/aocpmr/public_html/wp-content/themes/whitehousepro/functions.php on line 20
Line 20 refers to the last line of code... Any thoughts? The code is from wordpress.org and should be correct..

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this  

×