WordPress.org

Support

Support » Plugins and Hacks » [Resolved] Display number of search results using the Headway Theme

[Resolved] Display number of search results using the Headway Theme

  • I’m using the Headway theme and trying to display the number of search results on the search page. I inserted the code below (which you listed on your FAQ section to perform this task) into a custom code block but it’s not displaying the number.

    <?php echo 'Relevanssi found ' . $wp_query->found_posts . ' hits'; ?>

    I appreciate you may not be familiar with Headway so any help would be great.

    https://wordpress.org/plugins/relevanssi/

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Mikko Saari
    Participant

    @msaari

    Change it to

    <?php global $wp_query; echo 'Relevanssi found ' . $wp_query->found_posts . ' hits'; ?>

    That should fix it.

    Brilliant, that’s done the trick.

    Thanks for responding so quickly. I shall send a donation and spread the word amongst the Headway community about Relevanssi.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘[Resolved] Display number of search results using the Headway Theme’ is closed to new replies.