close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

I want to show 0 results if nothing has been searched rather than show all results

Thread began 3/14/2019 1:14 pm by jo271221 | Last modified 3/15/2019 8:32 pm by Ray Borduin | 750 views | 7 replies |

jo271221

I want to show 0 results if nothing has been searched rather than show all results

I found this resolution and I attempted to add on my page after line 27, that did not work and I tried after line 199. There is some code modification for sorting which I believe is complicating things.

Sign in to reply to this post

jo271221

I am attaching my page.

Sign in to reply to this post

Ray BorduinWebAssist

Please attach the page... There should be a "default where clause" setting in the database search. You can set it to "0 = 1" and that should return no results if no search is performed. (depending on the version you may need to set the default where clause to "WHERE 0 = 1")

Sign in to reply to this post
Did this help? Tips are appreciated...

jo271221

Assuming the wada_search.php is the file you need I have attached it.
Thank you,

Sign in to reply to this post

Ray BorduinWebAssist

on search-all-results.php on line 10 you have:

$WADbSearch1_DefaultWhere = "";

Try using:

$WADbSearch1_DefaultWhere = "WHERE 1=0";

If that doesn't work try just:

$WADbSearch1_DefaultWhere = "1 = 0";

Sign in to reply to this post
Did this help? Tips are appreciated...

jo271221

I tried both of those options and I am still getting all results.

Sign in to reply to this post

Ray BorduinWebAssist

There was some custom code on the page that overwrote how the search worked by default. I went in and fixed it.

Sign in to reply to this post
Did this help? Tips are appreciated...

jo271221

Thank You!

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...