Re: hiding blank MySQL results?
| From: | Raquel Rice | Date: | Sat, 05 Jan 2002 18:25:07 +0000 |
| Subject: | Re: hiding blank MySQL results? | ||
| References: | 1 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-15440@lists.php.net to get a copy of this message | ||
On Sat, 5 Jan 2002 01:12:21 -0000
Nathon Jones "Nathon Jones" <nathonjones@kirkmoor.com> wrote:
> Hi.
>
> I have a PHP page calling a set of results from a MySQL database.
> They
> appear in the following format on the results page:
>
> Title
> Description
> Link
>
> Problem I'm having. When a db record has an empty field (for
> example, no
> description), the results page leaves a gap where the description
> should be.
>
> How do I do a "hide if empty" thang to stop the gaps appearing?
>
> Really appreciate the help.
> Regards
> nathon
> nathonjones@kirkmoor.com
When I do something like that, I test the results before displaying
the page or the page section. Use your PHP to check the results.
If empty, then don't display.
--
Raquel
============================================================
Rarely do we find men who willingly engage in hard, solid thinking.
There is an almost universal quest for easy answers and half-baked
solutions. Nothing pains some people more than having to think.
--Martin Luther King, Jr.