GreyWolf
Elite Member
- Aug 17, 2009
- 1,862
- 5,847
Well I'm just in a really helpful mood tonight. 
Warning - these instructions are correct, but I am taking no responsibility. Don't ask me to troubleshoot your code if anything goes wrong. Do a backup before you start and then if anything does go wrong, you can just restore from your backups. This isn't a big deal to do this, but ...
I'm just sayin'.....
ya know what i mean....
OK kikiriki, here you go:
The Stripey v1.6 theme designer didn't bother making an options tab for the theme. Any changes you want to make have to be done with the theme editor, or using your website file manager or ftp.
To fix this from within WP here is what you need to do. This will only work if you have your stripey theme folder set to 755. Unless you have previously set your stripey theme folder to 755, then all you will be able to do is see the code you need to change.
That is all you need to get it to display excerpts and not the full article on your front page.
------------------------------------
You're done now if you want, the following is just an additional change you can make if you want.
Now, if you want to change the excerpts length, the default is 55. You can use the code given as long as you have wp version 2.9
It is the safest way so try it first, but it doesn't always work.
You'll need to change the excerpt length in your core files.
So there you go. I would suggest that before making changes to the files you make a backup copy just in case you make a mistake. It's easier to just replace the file with your backup than to find whatever stray character you accidentally added.
Before you make any changes to your core files it's always a really good idea to make a backup of your database, just in case. Your not changing anything major, but accidents happen.
Here are some additional sources
Warning - these instructions are correct, but I am taking no responsibility. Don't ask me to troubleshoot your code if anything goes wrong. Do a backup before you start and then if anything does go wrong, you can just restore from your backups. This isn't a big deal to do this, but ...
I'm just sayin'.....
ya know what i mean....
OK kikiriki, here you go:
The Stripey v1.6 theme designer didn't bother making an options tab for the theme. Any changes you want to make have to be done with the theme editor, or using your website file manager or ftp.
To fix this from within WP here is what you need to do. This will only work if you have your stripey theme folder set to 755. Unless you have previously set your stripey theme folder to 755, then all you will be able to do is see the code you need to change.
- log in to admin
- go to the Appearance tab
- click on Editor
That opens your theme editor - The Theme Files are listed on the right
Select the file you want to edit and make the changes. (I'll tell you which files in a minute)
- Go into your wp-content folder
- Go into your themes folder
- Go into your stripey-v1.6 folder
- Open index.php with your code editor
- On line 21 you will find this code (if it isn't on line 21 or your not using a code editor, just search for the_content)
PHP:<?php the_content('Read the rest of this entry »'); ?> - Change it to this
PHP:<?php the_excerpt('Read the rest of this entry »'); ?>
That is all you need to get it to display excerpts and not the full article on your front page.
------------------------------------
You're done now if you want, the following is just an additional change you can make if you want.
Now, if you want to change the excerpts length, the default is 55. You can use the code given as long as you have wp version 2.9
It is the safest way so try it first, but it doesn't always work.
- Go into your wp-content folder
- Go into your themes folder
- Go into your stripey-v1.6 folder
- Open functions.php with your code editor
- Add the code jeffers1957 posted above to the end of the file, right above the last } character. (change the 100 to whatever default length you want)
You'll need to change the excerpt length in your core files.
- Go into your wp-includes folder
- Open formatting.php with your code editor
- Search for $excerpt_length (should be around line 1812, or in older versions line 853)
- Once you find it change the excerpt length in this line to whatever you want it to be.
PHP:$excerpt_length = apply_filters('excerpt_length', 55);
So there you go. I would suggest that before making changes to the files you make a backup copy just in case you make a mistake. It's easier to just replace the file with your backup than to find whatever stray character you accidentally added.
Before you make any changes to your core files it's always a really good idea to make a backup of your database, just in case. Your not changing anything major, but accidents happen.
Here are some additional sources
Code:
http://lorelle.wordpress.com/2006/07/19/display-post-excerpts-only-in-wordpress/
http://codex.wordpress.org/Plugin_API/Filter_Reference/excerpt_length
http://itscalledwebdesign.com/tutorials/wp/change-excerpt-length-in-wp/