Reply To: Exclude certain characters of the search

Home Forums Product Support Forums Ajax Search Pro for WordPress Support Exclude certain characters of the search Reply To: Exclude certain characters of the search

Ernest Marcinko
Ernest Marcinko


I think you are using a different apostrophe character there.

If you try the l’activité or d’abord it’s going to work.
The ’ apostrophe is not same character as the ‘.

I’ve logged in with the FTP account and created a filtering function to replace the incorrect apostrophe automatically for you. It took me a while, because the functions.php file was in an incorrect encoding, but I fixed that for you as well. The code I appended there for future reference:

// An extra function for fixing the apostrophes for Ajax Search PRO
add_filter('asp_search_phrase_after_cleaning', 'asp_fix_apostrophe', 1, 1);

function asp_fix_apostrophe( $s ) {
  $s = mb_ereg_replace("'", "’", $s);
  return stripslashes($s);

This code remains after updates as well, you don’t have to worry 🙂

Ernest Marcinko

If you like my products, don't forget to rate them on codecanyon :)