close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Results pages show products even without search

Thread began 8/24/2016 1:26 pm by tmcbinc99963 | Last modified 8/25/2016 2:14 pm by Ray Borduin | 1242 views | 5 replies |

tmcbinc99963

Results pages show products even without search

On both my Prod_results page and news_results page it shows items before a search is performed. The items aren't related to any past search or from any search during the current session. I've cleared browser settings, but can't get them to go away. Not really a problem on the Prod_results page, as it will only be accessed via a search from the home page. But the news can only be searched from the news page itself.

Live view link in PM

Sign in to reply to this post

Ray BorduinWebAssist

The links you provided aren't working for me. I'd have to see the pages themselves to see why they return results before a search is performed.

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

tmcbinc99963

Two pages attached, plus corrected live view links.

Sign in to reply to this post

Ray BorduinWebAssist

Just update the Default Where clause in the DataAssist Search server behavior to: 0=1

That will force it to return no results by default until a search is performed. You could update it directly on line 15 of news_results.php as well.

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

tmcbinc99963

That worked. Is there a way to hide the entire Results form until after a search? Right now, 'Results' and 'no results found' appear always, regardless of whether a search is made. Tried moving the form source code and 'show if' statements around, but it throws the 'hidden field' and other syntax off.

Sign in to reply to this post

Ray BorduinWebAssist

You could use an IF statement to check the value of $WADbSearch1->whereClause to see if it is the default value to check if a search has been applied like:

php:
<?php

if ($WADbSearch1->whereClause == "0=1") {
?>
Code you want to not show
<?php

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

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