Forums

new WP-query() and search.php (1 post)

  1. doodlebee
    Member
    Posted 3 years ago #

    Just a quick question - I have a theme that I just wrote up, and it involves a custom query (using query_posts()) in the header to display random custom fields in the header.

    It works great on all pages - *except* search.php (my search results page). Instead, I get a huge MySQL database error.

    I'm wondering if this is common? I've noticed if I remove the custom query from the header, the search page displays fine - but I'd really like to keep it there. i thought that, because I'm using the new WP_query method (over just "query_posts()") that the two loops wouldn't affect each other, but apparently it is. So I was just wondering if this was common, and why it does this. Anyone know?

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.