<HTML><HEAD></HEAD>
<BODY dir=ltr>
<DIV dir=ltr>
<DIV style="FONT-FAMILY: 'Calibri'; COLOR: #000000; FONT-SIZE: 12pt">
<DIV>Pretty sure he knew what I was talking about even though I put a $ before
it and didn’t cap the WP part, people are intelligent enough to read
typo’s</DIV>
<DIV> </DIV>
<DIV> </DIV>
<DIV
style="FONT-STYLE: normal; DISPLAY: inline; FONT-FAMILY: 'Calibri'; COLOR: #000000; FONT-SIZE: small; FONT-WEIGHT: normal; TEXT-DECORATION: none">
<DIV style="FONT: 10pt tahoma">
<DIV> </DIV>
<DIV style="BACKGROUND: #f5f5f5">
<DIV style="font-color: black"><B>From:</B> <A title=edward.caissie@gmail.com
href="mailto:edward.caissie@gmail.com">Edward Caissie</A> </DIV>
<DIV><B>Sent:</B> Friday, September 13, 2013 5:57 PM</DIV>
<DIV><B>To:</B> <A title=theme-reviewers@lists.wordpress.org
href="mailto:theme-reviewers@lists.wordpress.org">Discussion list for WordPress
theme reviewers.</A> </DIV>
<DIV><B>Subject:</B> Re: [theme-reviewers] Feedback on use of query_posts please
- Badidea?</DIV></DIV></DIV>
<DIV> </DIV></DIV>
<DIV
style="FONT-STYLE: normal; DISPLAY: inline; FONT-FAMILY: 'Calibri'; COLOR: #000000; FONT-SIZE: small; FONT-WEIGHT: normal; TEXT-DECORATION: none">
<DIV dir=ltr>
<DIV>
<DIV>Using `WP_Query` is always going to be much better ...<BR><BR></DIV>...
here's another example, although from one of my plugins, it is used to create a
complete loop for the plugin's output: <BR><BR><A
href="https://github.com/Cais/bns-featured-category/blob/master/bns-featured-category.php#L249">https://github.com/Cais/bns-featured-category/blob/master/bns-featured-category.php#L249</A><BR><BR></DIV>That
is the actual call to `WP_Query` you can see above where its arguments are
generated and below where it is used.<BR></DIV>
<DIV class=gmail_extra>
<DIV> </DIV>
<DIV>Edward Caissie<BR>aka Cais.</DIV><BR><BR>
<DIV class=gmail_quote>On Fri, Sep 13, 2013 at 8:51 PM, Zulfikar Nore <SPAN
dir=ltr><<A href="mailto:zulfikarnore@live.com"
target=_blank>zulfikarnore@live.com</A>></SPAN> wrote:<BR>
<BLOCKQUOTE
style="BORDER-LEFT: #ccc 1px solid; MARGIN: 0px 0px 0px 0.8ex; PADDING-LEFT: 1ex"
class=gmail_quote>
<DIV>
<DIV dir=ltr>Sound advice there, cheers :)
<DIV> </DIV>
<DIV>And that link sets me off in the right direction, thanks for the
share.<BR><BR>
<DIV>
<HR>
From: <A href="mailto:philip@frumph.net"
target=_blank>philip@frumph.net</A><BR>To: <A
href="mailto:theme-reviewers@lists.wordpress.org"
target=_blank>theme-reviewers@lists.wordpress.org</A><BR>Date: Fri, 13 Sep
2013 17:38:49 -0700<BR>Subject: Re: [theme-reviewers] Feedback on use of
query_posts please - Bad idea?
<DIV>
<DIV class=h5><BR><BR>
<DIV dir=ltr>
<DIV style="FONT-FAMILY: 'Calibri'; FONT-SIZE: 12pt">
<DIV>You probably should be using new $wp_query</DIV>
<DIV> </DIV>
<DIV>mines not the best but here’s my blog.php</DIV>
<DIV> </DIV>
<DIV><A title=https://github.com/Frumph/comicpress/blob/master/blog.php
href="https://github.com/Frumph/comicpress/blob/master/blog.php"
target=_blank>https://github.com/Frumph/comicpress/blob/master/blog.php</A></DIV>
<DIV> </DIV>
<DIV> </DIV>
<DIV
style="FONT-STYLE: normal; DISPLAY: inline; FONT-FAMILY: 'Calibri'; FONT-SIZE: small; FONT-WEIGHT: normal; TEXT-DECORATION: none">
<DIV style="FONT: 10pt tahoma">
<DIV> </DIV>
<DIV style="BACKGROUND: #f5f5f5">
<DIV><B>From:</B> <A title=zulfikarnore@live.com
href="mailto:zulfikarnore@live.com" target=_blank>Zulfikar Nore</A> </DIV>
<DIV><B>Sent:</B> Friday, September 13, 2013 5:22 PM</DIV>
<DIV><B>To:</B> <A title=theme-reviewers@lists.wordpress.org
href="mailto:theme-reviewers@lists.wordpress.org" target=_blank>Theme
Reviewers</A> </DIV>
<DIV><B>Subject:</B> [theme-reviewers] Feedback on use of query_posts please -
Bad idea?</DIV></DIV></DIV>
<DIV> </DIV></DIV>
<DIV
style="FONT-STYLE: normal; DISPLAY: inline; FONT-FAMILY: 'Calibri'; FONT-SIZE: small; FONT-WEIGHT: normal; TEXT-DECORATION: none">
<DIV dir=ltr>I've read around that using query_posts is bad but I've seen many
a themes using it and get away with it.
<DIV> </DIV>
<DIV>My case is I'm trying to put together a template-blog.php for StrapVert
and this is what I've come up with so far:</DIV>
<DIV> </DIV>
<DIV>
<DIV>add_filter('option_show_on_front', '__return_false');</DIV>
<DIV> global $wp_query;</DIV>
<DIV> query_posts(array(</DIV>
<DIV><SPAN style="WHITE-SPACE: pre-wrap"></SPAN> 'paged' =>
$wp_query->get('paged'),</DIV>
<DIV><SPAN style="WHITE-SPACE: pre-wrap"></SPAN> 'post__not_in' =>
get_option('sticky_posts'),</DIV>
<DIV> ));</DIV>
<DIV> </DIV>
<DIV> global $more; $more = 0;</DIV>
<DIV> get_template_part('index-blog');</DIV>
<DIV> $more = 1;</DIV>
<DIV>remove_filter('option_show_on_front', '__return_false');</DIV>
<DIV> </DIV>
<DIV> wp_reset_query();</DIV>
<DIV>wp_reset_postdata();</DIV></DIV>
<DIV> </DIV>
<DIV>But before I add these changes to the theme and submit an update I'd like
some feedback on "How Really Bad" is query_posts and can I "get away" with the
above?</DIV>
<DIV> </DIV>
<DIV>Thanks in advance,</DIV>
<DIV>Zulf </DIV></DIV><BR>
<HR>
_______________________________________________<BR>theme-reviewers mailing
list<BR><A href="mailto:theme-reviewers@lists.wordpress.org"
target=_blank>theme-reviewers@lists.wordpress.org</A><BR><A
href="http://lists.wordpress.org/mailman/listinfo/theme-reviewers"
target=_blank>http://lists.wordpress.org/mailman/listinfo/theme-reviewers</A><BR></DIV></DIV></DIV><BR>_______________________________________________
theme-reviewers mailing list <A
href="mailto:theme-reviewers@lists.wordpress.org"
target=_blank>theme-reviewers@lists.wordpress.org</A> <A
href="http://lists.wordpress.org/mailman/listinfo/theme-reviewers"
target=_blank>http://lists.wordpress.org/mailman/listinfo/theme-reviewers</A></DIV></DIV></DIV></DIV></DIV></DIV><BR>_______________________________________________<BR>theme-reviewers
mailing list<BR><A
href="mailto:theme-reviewers@lists.wordpress.org">theme-reviewers@lists.wordpress.org</A><BR><A
href="http://lists.wordpress.org/mailman/listinfo/theme-reviewers"
target=_blank>http://lists.wordpress.org/mailman/listinfo/theme-reviewers</A><BR><BR></BLOCKQUOTE></DIV>
<DIV> </DIV></DIV>
<P>
<HR>
_______________________________________________<BR>theme-reviewers mailing
list<BR>theme-reviewers@lists.wordpress.org<BR>http://lists.wordpress.org/mailman/listinfo/theme-reviewers<BR></DIV></DIV></DIV></BODY></HTML>