howster2010
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: Add pagination when calling posts from category. Using WP3Hi,
At its most basic level – should the below work for news.php<?php /*Template Name: news*/?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>Untitled Document</title> </head> <body> <?php $paged = (get_query_var('paged')) ? get_query_var('paged') : 1; $my_query = new WP_Query("category_name=latest-news&showposts=2&paged=$paged"); ?> </body> </html>..or do i need additional code at the top for wp to understand. Is it compulsory to use header,sidebar and footer.php as embeds? Thanks
Forum: Fixing WordPress
In reply to: Add pagination when calling posts from category. Using WP3Thanks vtxyzzy but that code wouldnt work for me unfortunately. It displayed nothing strangely. Pagination just wont kick in but title and content pulls in fine with my own code above. New to wp so at experimental stages.
I created a custom page news.php that i put the above code into and am using the default twentyten loop.php file. If anyone has a sample of code for pulling in title and content with pagination it wud be much appreciated.Maybe i should be using some other theme to build off? Something basic that someone may recommend?
THANKSForum: Fixing WordPress
In reply to: limit posts per page in news section – custom templateI am working off the twentyten theme if it helps.
Forum: Fixing WordPress
In reply to: Make page unsearchable in search formI noticed that setting the page to draft status works but is there a more concrete method? Draft will make it unsearchable but the pae is still accessible