- Impact
- 9
This is for a widget that displays returns results for the last 30 days ..I cant figure out how to change for last 48 hours... the database uses timestamp for dates also..
//Min & Max
$Price = "SELECT AVG(`price_snow`),AVG(`price_rain`),AVG(`price_spread`) FROM
`prices` WHERE `approved`='1' AND `archive`!='1'";
$Min = $Db->FetchArray($Price);
// Set price variables
$avg_snow_price = round($Min['AVG(`price_snow`)'], 2);
$avg_rain_price = round($Min['AVG(`price_rain`)'], 2);
$price_spread = round($Min['AVG(`price_spread`)'],2);
My usual database.php script person has apparently taken a leave of absense.. in College
//Min & Max
$Price = "SELECT AVG(`price_snow`),AVG(`price_rain`),AVG(`price_spread`) FROM
`prices` WHERE `approved`='1' AND `archive`!='1'";
$Min = $Db->FetchArray($Price);
// Set price variables
$avg_snow_price = round($Min['AVG(`price_snow`)'], 2);
$avg_rain_price = round($Min['AVG(`price_rain`)'], 2);
$price_spread = round($Min['AVG(`price_spread`)'],2);
My usual database.php script person has apparently taken a leave of absense.. in College














