• Resolved cheyenne711

    (@cheyenne711)


    Hello,

    A lot of our products have two or more words in them and people often use hyphens when searching. Is there a way to automatically account for hyphens instead of having to use tags on each one?

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author ILLID

    (@mihail-barinov)

    Hi,

    Not sure that I fully understand your problem.

    Can you tell me examples of some search queries that you have problem with?

    Regards

    Thread Starter cheyenne711

    (@cheyenne711)

    An example would be flat washer. If the tag flat-washer is not added then all of the flat washers to do not appear Only the ones with the tags “flat-washer” show up. If you type in flat washer then all of the flat washers appear.

    Plugin Author ILLID

    (@mihail-barinov)

    Please try to use following code snippet:

    add_filter('aws_pre_normalize_string', 'my_aws_pre_normalize_string');
    function my_aws_pre_normalize_string( $string ) {
        $string = str_replace( array( '-', '-' ), ' ', $string );
        return $string;
    }
    Thread Starter cheyenne711

    (@cheyenne711)

    That worked. Thank you so much!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Hyphen in Search Results’ is closed to new replies.