PHP and Dreamweaver Dynamic Dropdown Show All Records

Posted on 2011-04-25
Medium Priority
Last Modified: 2012-05-11
I have a dynamic dropdown and dynamic search $GET form and it's using a dynamic dropdown as the source.  All works fine, except how do I put an option on there to remove the filter, in other words, showing all records again in case the user wants to see all the records again?
Question by:palmtreeinfotech
  • 2
LVL 111

Accepted Solution

Ray Paseur earned 1000 total points
ID: 35459457
Dreamweaver often stands in the way of good programming practices; someone else might be able to help with that part.  The way I would approach this is to have a test for an element of $_GET and if it is empty or says something logical like "all" I would eliminate the WHERE clause from the query that creates the record set.
LVL 70

Assisted Solution

by:Jason C. Levine
Jason C. Levine earned 1000 total points
ID: 35461523
If the filter is applied by a form submit, just change the form to allow the user to submit a blank value and then apply Ray's advice to complete the action.

Author Comment

ID: 35463349
Cool.  Thanks Ray and Jason.  How would I allow a blank submit from a form field and attach that to a *.* query?

Author Closing Comment

ID: 35472601
I may post again when I get to the part I need.  Thanks guys!

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I imagine that there are some, like me, who require a way of getting currency exchange rates for implementation in web project from time to time, so I thought I would share a solution that I have developed for this purpose. It turns out that Yaho…
Developers of all skill levels should learn to use current best practices when developing websites. However many developers, new and old, fall into the trap of using deprecated features because this is what so many tutorials and books tell them to u…
The viewer will learn how to count occurrences of each item in an array.
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
Suggested Courses
Course of the Month17 days, 10 hours left to enroll

830 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question