Quantcast
Channel: PHP Freaks: PHP Help
Viewing all articles
Browse latest Browse all 13200

PHP, MySqli comparing and displaying results

$
0
0

I’m curious as to what other developers do to compare Database results for web display.

 

Simple example:

 - select sum of all my expenses, sum of all my payments received; 

 - Display a table with the results

 - If expenses is higher than the payments display table background in red, or if payments is higher display table background in Green.  I can cobble together an if -> then - and have 2 separate tables depending on what is higher..  But that sounds like a long road, or maybe so - but the right road..  Just wondering what other people do..

 - I'm not really a "beginner" but my training has been OTJ..  Just looking for a bit of experienced advice.


Viewing all articles
Browse latest Browse all 13200

Trending Articles