Please or Register to create posts and topics.

Have Asgaros Forum Posts show up in WordPress Core's Search

I’m interested in having Asgaros Forums Posts show up in WordPress Core’s default search. Is this something that can be done via a plugin or will require custom development? If custom development, could you point me in the right direction?

Would something like https://searchwp.com/ work because it searches “Custom Fields Content”?

Hello @bryancasler

When I developed the search-functionality I planned to integrate search-results directly into the WordPress Core search functionality. The problem why I implemented my own search-engine at the end was the lack of an official search API which can be used to search content inside custom tables. Of course it would be possible to add the results to the core which some hardcoded query-modifications via filters and hooks. You can find an example in the old ticket here:

https://github.com/Asgaros/asgaros-forum/issues/7

But this would lead to a lot of problems, for example possible incompatibilities with other plugins and the risk, that after an update of WordPress the search-functionality would not work anymore.

As mentioned before, Asgaros Forum uses its own tables and not custom-fields inside of custom WordPress post-types. So if there is a plugin which supports querying above custom database tables, there will be a chance that it works. Otherwise you have to apply the before mentioned core-hack which is very risky.

If you want to support the development of Asgaros Forum, you can leave a good review or donate. Thank you very much!

Thanks for the response. Having that link in Github could prove helpful. For the current site I’m working on I ended up removing the sitewide search and implemented a search bar (via WPSearch and FacetsWP) only on Resources Pages, with a search that only returns Resource. I think this will work in this instance, but not sure about future scenarios. If I end up doing any work on this I’ll see if it’s anything I can contribute back.

Asgaros has reacted to this post.
Asgaros

I use Ajax Search pro plugin and it is bad that the posts can’t show up the Wordpress Core search.