\n"; echo ""; echo "\n"; echo "\n"; echo "\n"; echo "\n"; $get = mysql_query("SELECT * from accounting WHERE company = '4' and (collectiondate>='2013-01-01') and (collectiondate<='2013-01-31')GROUP BY collectiondate"); while ($row = mysql_fetch_assoc($get)) { $collectiondate = $row['collectiondate']; $totalgl = $row['totalgl']; $cash = $row['cash']; echo "\n"; } echo "\n"; echo "
Cash In and Collections 
CollectionsGC Sales
$collectiondate$cash$totalgl
\n"; echo ""; ?>