Topic: Add a 'Read More' button to footer of Featured posts
Can anyone please advise me on how I can add a 'Read More' button (like the 'quick-read-more' that is used in index-news posts) to the index-featured posts on the home page?
Thanks!
Arras WordPress Theme Community Forums
Community support for Arras and other WordPress projects
You are not logged in. Please login or register.
Arras 1.5.2-RC2 Now Available: Download Here
Forum Rules: Please ensure that you have clearly read and understood the forum rules before posting.
User Confirmations / Password Reminders: Please check your spam folder before emailing for help if you have not received the confirmation or password reset emails.
Arras WordPress Theme Community Forums → General Help → Add a 'Read More' button to footer of Featured posts
Can anyone please advise me on how I can add a 'Read More' button (like the 'quick-read-more' that is used in index-news posts) to the index-featured posts on the home page?
Thanks!
That'll require rewriting of either template.php or tapestries.php, depending on which version you use of Arras Theme.
I'm using Arras 1.4.2.
Is this a big job? And am I likely to run into problems?
Open template.php
Search for:
<div class="entry-summary">
<?php
if ($display_type == 'default') {
echo arras_strip_content( get_the_excerpt(), arras_get_option('node_based_limit_words') );
} else {
echo get_the_excerpt();
?>
<p class="quick-read-more"><a href="<?php the_permalink() ?>" title="<?php printf( __('Permalink to %s', 'arras'), get_the_title() ) ?>">
<?php _e('Read More', 'arras') ?>
</a></p>
<?php
}
?>Change it into:
<div class="entry-summary">
<?php /*
if ($display_type == 'default') {
echo arras_strip_content( get_the_excerpt(), arras_get_option('node_based_limit_words') );
} else { */
echo get_the_excerpt();
?>
<p class="quick-read-more"><a href="<?php the_permalink() ?>" title="<?php printf( __('Permalink to %s', 'arras'), get_the_title() ) ?>">
<?php _e('Read More', 'arras') ?>
</a></p>
<?php /*
}
*/ ?>And add this to your default.css:
.posts-default .quick-read-more { margin: 10px 0 0; }
.posts-default .quick-read-more a:link, .posts-quick .quick-read-more a:visited { background: url(../../images/feed-title-white.jpg) top repeat-x #EFEFEF; color: #000; text-decoration: none; padding: 4px 10px; margin: 0; border: 1px solid #CCC; font-weight: 700; zoom: 1; *display: inline; display: inline-block; }
.posts-default .quick-read-more a:hover { background: #383332; color: #FFF; }Thanks so much!! The links have been inserted!
The styling still isn't working for some reason tho... I see where you were going with it, but I'm not sure why its not picking it up.
Any ideas?
Did you add it to your stylesheet? I noticed you don't use the default.css
yes I did - I'm using twintrack.css
It seems to be ok in all browsers except chrome...
Is this fix different for 1.4.3? I am unable to find anything resembling this in template.php.
That's in tapestries.php for 1.4.3.1
Would you mind updating this for 1.5.0.1?
Would you mind updating this for 1.5.0.1?
It will be very helpful to me too..
Thank!
I'm using 1.5.0.1, and would love to add a 'Read more' or '...' to the text extract in the node based home page display as well. It looks like the fix above doesn't apply to 1.5.0.1? Thanks for any help!
In the meantime I am just adding a manual excerpt to each post and finishing it with '...' or 'Read more'. If you've got a lot of posts that would not be fun. (Go to edit post, then scroll down until you see the 'Excerpt' box and you can add whatever text you would like to appear.)
Last edited by KathH (2011-02-16 22:56:43)
Powered by PunBB, supported by Informer Technologies, Inc.
Currently installed 9 official extensions. Copyright © 2003–2009 PunBB.
Generated in 0.042 seconds, 12 queries executed