• Resolved Luisle

    (@luisle)


    Hi, i have a problem when i search with the search long when i looking for a name with long=3… for example, i search “lopez” and show all the “lopez”, i search “lope” and show all the “lopez”, but i search “lop” and don’t show anything.

    I have names with 3 letters like “gil” or “saz”, and if i set that, don’t show any search result.

    Is it possible to change de min number of letters to do a search? i think now is set as 4, and i want to set it as 3.

    Regards.

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

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author Steven

    (@shazahm1hotmailcom)

    The min length character count is already set to a single character in the current versions of Connections (10.4.39). I see you have version 10.4.9 installed on your site. That is over a year old and may need to update.

    That said, this still may not change your results as some web hosts have the WP database set up to ignore search terms that are only 2 or 3 characters in length.

    I hope this helps; please let me know.

    Thread Starter Luisle

    (@luisle)

    Hi, what is the price of the update? i need to see it to my client, because that could be the problem, because is impossible in a WP database set to ignore searchs with 2 or 3 characters…

    I wait your answer, and where can i buy the update.

    Regards.

    Plugin Author Steven

    (@shazahm1hotmailcom)

    RE: impossible in a WP database set to ignore searchs with 2 or 3 characters

    This is possible and likely as the default for MySQL (one of the primary databases used for WP) is 2 characters for FULLTEXT matches. Connecctions switches to LIKE matches or short words such as 2–3 characters.

    RE: what is the price of the update?

    There is no fee. Navigate to the WordPress plugins admin page, scroll to the Connections Business Directory plugin row, and click the update now link.

    I hope this helps; please let me know.

    Thread Starter Luisle

    (@luisle)

    Hi, i’m a little afraid to update, because i have change files to show like you see now… so that, do you know the line where you limit the search to 4 or more characters? i try to search it but i don’t find.

    Regards.

    Plugin Author Steven

    (@shazahm1hotmailcom)

    The limit in 10.4.9 is already set to three characters.

    As mentioned, in current versions of Connections the minimum was set to one.

    To make the exact change, you need to edit the
    ../wp-content/plugins/includes/Request/Search.php file.

    Edit line 43. Change the 3 to a 1.

    Edit the
    ../wp-content/plugins/includes/class.retrieve.php file.

    Edit line 2938.

    Change it from:

    if ( strlen( $term ) >= 2 && strlen( $term ) <= 3 ) {

    to:

    if ( strlen( $term ) >= 1 && strlen( $term ) <= 3 ) {

    I do not think this will make a difference in your results if the WP database minimum character length is set to 4. One setting change you can try… navigate to the Connections Settings admin page and click the Search tab. Disable the FULLTEXT option and save the change. This will allow Connections to only use a basic string match, and results should return when a match is found from the beginning of the string instead of relevancy based (already the default for short word searches). For example, lop should return Lopez since it starts with lop.

    I hope this helps!

    ps. If the only edit you made to Connections was to display the fallecido.png image. I suspect you made the change only to the Circled template. If that is the case, you should be able to update Connections without issue.

    You can use the Download Plugin plugin to download the version of Connections you have installed:

    Update Connections and if there is an issue, you can reinstall Connections from the version you downloaded.

    Thread Starter Luisle

    (@luisle)

    Thanks! you are the best!

    Regards.

    Plugin Author Steven

    (@shazahm1hotmailcom)

    No problem; happy to help! Which solution helped?

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Search long’ is closed to new replies.