Can anyone explain how I can change the below code to exclude posts that are password protected? I know I can do so with an if statement within the while statement but I want to exclude them from the WP_Query point.
$pq = new WP_Query(array('post_type' => $ptype, 'showposts' => $pshow ));
You can make it happen with a
post_where
filter, just before you execute your query: