BUG: 404 error after certain WordPress search results

Switched database engine to mysqli if it's available for compatibility with PHP 7