how can I add a “read more” tag directly in the template?

The code would probably be something like this: echo ‘<a href=”‘ . get_permalink() . “#more-{$post->ID}\” class=\”more-link\”>”.__( ‘Read more &gt;’, ‘your-theme’ ). ‘</a>’; Check out the source on how WordPress does it: http://core.trac.wordpress.org/browser/tags/3.3.1/wp-includes/post-template.php#L219 This has to be inside the loop to work and the $post global has to be visible in the current scope.

Extra text… after read more tag

The more-Tag have a filter, you can enhance this with a small plugin like the follow example. <?php /** * Plugin Name: br after more-Tag * Description: Add content of var $extra_more after more-Tag * Version: 0.0.1 */ ! defined( ‘ABSPATH’ ) and exit; add_filter( ‘the_content_more_link’, ‘custom_more_link’, 9999 ); function custom_more_link( $more_link ) { $extra_more=”<br>”; … Read more

Wrap More Link in Div

I found a solution on the WordPress forums, if anyone is trying to do the same thing here is the solution: http://wordpress.org/support/topic/custom-read-more-text-wrapped-in-a-div I added the following to my functions file: function wrap_readmore($more_link) { return ‘<div class=”post-readmore”>’.$more_link.'</div>’; } add_filter(‘the_content_more_link’, ‘wrap_readmore’, 10, 1); Thanks, Josh

Read more to open external link

You just need to add target=”_blank” to the anchor tag. function remove_more_link_scroll( $link ) { $link = str_replace(‘>’,’ target=”_blank”>’, $link); return $link; } add_filter( ‘the_content_more_link’, ‘remove_more_link_scroll’ ); I feel compelled to state that I consider forcing new tabs/windows to be very unfriendly behavior, and if you search the web you will see that I am … Read more

Remove the More Link

You need a filter on the_content_more_link. else { // They aren’t in the paying group function strip_more_link($link,$linktext) { remove_filter(‘the_content_more_link’,’strip_more_link’,1); return $linktext; } add_filter(‘the_content_more_link’,’strip_more_link’,1,2); global $more; $more = 0; the_content(‘<b>Interested in reading the rest of this article? You just be a subscriber to continue reading.</b>’); } It may be more efficient, or neater, to write a … Read more

How to use Readmore.js? [closed]

The problem is related to wordpress loading jquery in noconflict mode in which the $ shortcut does not work. Try to replace it with an explicit jQuery or wrapt the relevant code in a way which will decalre $ like in the following example jQuery(document).ready(function ($) { $(‘article’).readmore(); });

More quicktag driving me nuts

The “read more” link is essentially a navigational device meant to point visitors to a full version of a piece of some excerpted content. A single.php of any post type is the full version, therefore it is 100% in the nature of <!– more –> to not appear on single custom post type pages. If … Read more

Excerpt Is Disappeared

you have forgotten to return the unaltered $content if this is not a single post: function google_adsense($content) { if(is_single()) { global $post; $thePostID = $post->ID; $more_span = ‘<span id=”more-‘ .$thePostID.'”></span>’ ; return str_replace($more_span, $more_span . ” ” . google_reklam_ekle(), $content); } else { return $content; } }