Strict Standards: Redefining already defined constructor for class bbdb in /home/themes/public_html/forums/bb-includes/db-mysql.php on line 12

Strict Standards: Declaration of BB_Walker_Blank::start_lvl() should be compatible with BB_Walker::start_lvl($output) in /home/themes/public_html/forums/bb-includes/classes.php on line 1127

Strict Standards: Declaration of BB_Walker_Blank::end_lvl() should be compatible with BB_Walker::end_lvl($output) in /home/themes/public_html/forums/bb-includes/classes.php on line 1127

Strict Standards: Declaration of BB_Walker_Blank::start_el() should be compatible with BB_Walker::start_el($output) in /home/themes/public_html/forums/bb-includes/classes.php on line 1127

Strict Standards: Declaration of BB_Walker_Blank::end_el() should be compatible with BB_Walker::end_el($output) in /home/themes/public_html/forums/bb-includes/classes.php on line 1127

Warning: Cannot modify header information - headers already sent by (output started at /home/themes/public_html/forums/bb-includes/db-mysql.php:12) in /home/themes/public_html/forums/my-templates/kakumei-variant/rss2.php on line 1
ThemeShaper Forums Topic: query_posts and is_home issues http://forums.themeshaper.com/ Help In Shaping WordPress Themes en Wed, 27 May 2015 19:53:23 +0000 middlesister on "query_posts and is_home issues" http://forums.themeshaper.com/topic/query_posts-and-is_home-issues#post-22305 Wed, 13 Jul 2011 19:52:17 +0000 middlesister 22305@http://forums.themeshaper.com/ <p>This is expected behaviour. Using query_posts will make a new database query, and changing the query will affect global values including changing the conditionals.<br /> <a href="http://codex.wordpress.org/Function_Reference/query_posts" rel="nofollow">http://codex.wordpress.org/Function_Reference/query_posts</a></p> <p>You might get lucky if you put in a "wp_reset_query()" immediately after the loop. </p> jmtmay on "query_posts and is_home issues" http://forums.themeshaper.com/topic/query_posts-and-is_home-issues#post-22296 Wed, 13 Jul 2011 03:48:53 +0000 jmtmay 22296@http://forums.themeshaper.com/ <p>Darrenc, Did you ever figure this out? I'm having the same problem. </p> <p>I'm using query_posts, then try to use is_home and it doesn't work. As soon as I take out the query_posts the is_home works. </p> darrenc on "query_posts and is_home issues" http://forums.themeshaper.com/topic/query_posts-and-is_home-issues#post-19242 Thu, 17 Feb 2011 16:41:07 +0000 darrenc 19242@http://forums.themeshaper.com/ <p>with respect, i don't think that's the most elegant solution. i've done it in 4 lines of code and without creating additional pages to manage. instead of making another homepage template, i could use the childtheme_override_index_loop() in function.php, but i was option for a surgically precise modification since i only need to change 2 things. </p> <p>i'm sure there is a way, and i thought query_posts was it... but like i said, i am getting those weird side effects and am curious why. </p> lastraw on "query_posts and is_home issues" http://forums.themeshaper.com/topic/query_posts-and-is_home-issues#post-19231 Thu, 17 Feb 2011 04:28:38 +0000 lastraw 19231@http://forums.themeshaper.com/ <p>I prefer making a homepage template then adding the code you can find here:<br /> <a href="http://mygraphicfriend.wordpress.com/2010/01/20/wordpress-create-a-page-template-that-displays-posts-from-a-category-that-has-the-same-name-as-the-page/#comment-133" rel="nofollow">http://mygraphicfriend.wordpress.com/2010/01/20/wordpress-create-a-page-template-that-displays-posts-from-a-category-that-has-the-same-name-as-the-page/#comment-133</a><br /> (via Pictrix) </p> darrenc on "query_posts and is_home issues" http://forums.themeshaper.com/topic/query_posts-and-is_home-issues#post-19229 Thu, 17 Feb 2011 01:09:11 +0000 darrenc 19229@http://forums.themeshaper.com/ <p>on the homepage of my site i want to simply display 3 posts from a certain category. i devised this code, put into my child functions.php:</p> <pre> add_action("thematic_indexloop", "font_page_loop"); function font_page_loop(){ query_posts('posts_per_page=3&#38;cat=40'); } </pre> <p>however i noticed that now when i try to do other things on the page using "is_home()" they don't work anymore... almost like the homepage doesn't believe it is a homepage anymore.</p> <p>i know that i can workaround this by testing for is_category('40') instead, but my curiosity is getting the better of me:</p> <p>- what is actually happening here?<br /> - is this the best way to be accomplishing what i want?<br /> -- if not... then what is a better way?</p> <p>thanks for any replies. </p>