Support » Plugin: Advanced Woo Search » WC Compatibility & search results queue question

  • First off, GREAT job. Works pretty well & smoothly.
    I would like first to know if it is compatible with the latest WooCommerce 3.0? I am preparing to upgrade from WC 2.6.14.

    Second, it seems a little particular when it comes to searching fields [with special characters]. For instance, on my site, products are titled with dimensions

    4″ X 6″ Product title
    2″ X 4″ Product title

    If entered 4×6 without the spaces [between the x], no results.
    If entered, 4″ X 6″, it finds products with a capital X but avoids 4″, 6″, or the combo.

    Is there a way to get it to avoid that? Maybe use a [different] regular expression?

    Many thanks
    Ammon

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

    (@mihail-barinov)

    Hi,

    First of all thanks for your kind words.

    1. Yes, plugin is fully compatible with the latest WooCommerce version.

    2. Try to open common.js file, find line

    searchFor = searchFor.replace( /[~!@#$%^&*()_|+\?;:'”,.<>\{\}\[\]\\\/]/gi, ” );`

    and replace ” from it

    Thread Starter amirand926

    (@amirand926)

    I should replace the line with that code? Or did you mean that I should remove the quotation marks from that line?

    Thread Starter amirand926

    (@amirand926)

    Line 28 of common.js has the following: (i am the first one, you typed the second):
    28 searchFor = searchFor.replace( /[`~!@#$%^&*()_|+\?;:'”,.<>\{\}\[\]\\\/]/gi, ” );
    28 searchFor = searchFor.replace( /[~!@#$%^&*()_|+\?;:’”,.<>\{\}\[\]\\\/]/gi, ” );`

    The one you typed previously removes that first single backtick (`) and exchanges the double quotation marks at the end with two single quotation (”) marks.

    I pasted for easy reference and comparison but do you want me to replace that line with yours? (Correct me if I am wrong but I also assumed the single quote you typed previously at the end after the semicolon was a typo)

    Thanks in advance!

    Plugin Author ILLID

    (@mihail-barinov)

    Its was a typo ( this forum explain ` as a code tag ).

    You just need to remove ” from the list of special chars in regular expresion.

    • This reply was modified 6 years, 11 months ago by ILLID.
    Thread Starter amirand926

    (@amirand926)

    I have removed it but it does not seem to provide results. I switched the minimum characters down to 2 so that I could search for the two chars: 4″
    However, it does not show proper results.
    I switched it back to minimum 3 characters and when I type,

    4″ x 6″ <–Everything with a single x shows up 4″ x 6″, 2.25″ x 1″, etc.
    5″ <– No results
    1″ <– No results
    2″ <– No results
    etc

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘WC Compatibility & search results queue question’ is closed to new replies.