pagination/prev and next page links not showing

OK, it seems that we have two errors here: You should use posts_nav_link() instead of previous_post_link() and next_post_link(). The functions you used point to previous/next posts, not pages. You can refer to the WordPress Codex for more information. You should place posts_nav_link() after endwhile so that it is not repeated for every single post excerpt … Read more

How to defeat “Blog pages show at most __ posts” setting in the loop?

Instead of using the default loop, perhaps try building your own query. Basically, it’ll look something like this: $your_posts = get_posts(‘cat=123&posts_per_page=123’); foreach ($your_post as $post) { do_something-with($post); } You can display all posts by either use the param ‘posts_per_page’=>-1 or nopaging=true. (Not sure why someone voted this down? IMHO said person should comment on how … Read more

Add rel to all images in a post

something like this can be useful: function image_tag($html, $id, $alt, $title) { return preg_replace(array( “https://wordpress.stackexchange.com/”.str_replace(‘//’,’//’,get_bloginfo(‘url’)).’/i’, ‘/s+width=”d+”/i’, ‘/s+height=”d+”/i’, ‘/alt=””/i’ ), array( ”, ”, ”, ‘alt=”‘ . $title . ‘”‘ ), $html); } add_filter(‘get_image_tag’, ‘image_tag’, 0, 4);

have_posts() return false on single post

Late answer but, one possible scenario this could be happening is if you register two custom post types with the same permalink slug. You can debug this by doing a var_dump of the global variable $wp_query. global $wp_query; var_dump($wp_query); Check to see if the post_type in the query matches the post type of the page … Read more