ThemeForest

Avada search doesn't search Pages

2 posts
  • Bought between 1 and 9 items
  • Has been a member for 0-1 years
TangentWeb says

Hi All,

Bit worried about search form not finding any results on pages.

We are building a static client site that requires search and nothing comes up because we have all pages!

Any help? Tried heaps of search plugins but none work. Relevanssi is one we tried…

2 posts
  • Bought between 1 and 9 items
  • Has been a member for 0-1 years
TangentWeb says

Hey what do yo know? I worked it out!

Avada seems to have control over the default search, so you have to disable it. I edited Theme Functions (functions.php)

At the very end of that file, just comment out the following (by adding // to start of each line):

function pyre_SearchFilter($query) { if ($query->is_search) { $query->set(‘post_type’, ‘post’); } return $query; } add_filter(‘pre_get_posts’,’pyre_SearchFilter’);

Pretty simple I know but did the job for me!

1 post
  • Bought between 1 and 9 items
  • Has been a member for 0-1 years
IceVista says

Thanks TangentWeb, I’ve been trying to figure this out too. Why would one limit this without have it configurable via an option? Weird!

Now on to how to make the results look semi decent…

1 post
  • Bought between 1 and 9 items
  • Has been a member for 0-1 years
bboyharribo says

Hey

I have purchased this and when i put in my codes it still doesnt let me in?

by
by
by
by
by