function GET_TOTAL_DATA ($search, $tableName, $lookFor = "id", $whereStatement = "userid", $countRows = false, $add = "") {
$ret = 0;
//* DEBUG: */ echo $search."/".$tableName."/".$lookFor."/".$whereStatement."/".$add."<br />\n";
- if (empty($search)) {
+ if ((empty($search)) && ($search != "0")) {
// Count or sum whole table?
if ($countRows === true) {
// Count whole table