*

Web

  • ****
  • 183 posts
Recently searched
« on: February 23, 2021, 07:02:43 AM »
How to enable Recently searched ?

Marked as best answer by frosticek on February 23, 2021, 07:27:56 AM
*

MB Themes

Re: Recently searched
« Reply #1 on: February 23, 2021, 07:27:53 AM »
@Web
oc-admin > settings > latest searches
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots

*

Web

  • ****
  • 183 posts
Re: Recently searched
« Reply #2 on: February 23, 2021, 08:33:44 AM »
@mbthemes

Save the latest user searches enabled

but not showing

*

MB Themes

Re: Recently searched
« Reply #3 on: February 23, 2021, 08:50:44 AM »
@Web
Once users will start to do search, it will show up.
However theme must support it as well and beta does not, you may reuse this code from Veronika theme:
Code: [Select]
<?php if(osc_is_search_page()) { ?>
  <?php osc_get_latest_searches() ?>
  <?php if(osc_count_latest_searches() > 0) { ?>
    <div id="latest-search">
      <div class="inside">
        <span><?php _e('Recent Searches''veronika'); ?>:</span>

        <?php while( osc_has_latest_searches() ) { ?>
          <a href="<?php echo osc_search_url(array('page' => 'search''sPattern' => osc_latest_search_text())); ?>"><?php echo osc_latest_search_text(); ?></a>
        <?php ?>
      </div>
    </div>
  <?php ?>
<?php ?>
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots