close ad
Install the LAtest Updates to Work with CC 2017 and CC 2018
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Search results not showing if not exact.

Thread began 6/02/2017 12:25 pm by BillHobbs | Last modified 6/02/2017 2:06 pm by Ray Borduin | 242 views | 4 replies |

BillHobbs

Search results not showing if not exact.

I have a search form on a funeral home site and I want to search all the possible results. The problem is the results only show if the name is exact.
Example:
If the person I'm looking for is Judy Harrison Garner she would show up if I searched Judy, Judy Harrison, Harrison Garner or Judy Harrison Garner, but I want the user to be able to search for Judy Garner and she would show up. Here is how I have the results coded.

$WADbSearch1->addComparisonFromEdit("visitName","visitName","AND","Includes",0);

Sign in to reply to this post

Ray BorduinWebAssist

You have to use the "keyword" search type for this with a space character as the "Implied AND"

Sign in to reply to this post

BillHobbs

That didn't work I get everything now.

//comparison list additions
$WADbSearch1->keywordComparison($KeyArr1,"".((isset($_POST["visitName"]))?$_POST["visitName"]:"") .""," ","=","%20AND%20","%20OR%20","%22","%22",0);

Sign in to reply to this post

Ray BorduinWebAssist

Are you using POST or URL Parameters to pass the search value? It looks like you have it set to "=" instead of "Includes" and you have your implied AND set to " AND " instead of " ".

Maybe this would work:
$WADbSearch1->keywordComparison($KeyArr1,"".((isset($_GET["visitName"]))?$_GET["visitName"]:"") .""," ","Includes","%20",",%20","%22","%22",0);

Sign in to reply to this post

BillHobbs

That was the charm. Thanks.

Sign in to reply to this post

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...