Example #1
0
 echo "  <tr class=\"record\">\n";
 formatCallDate($row['calldate'], $row['uniqueid']);
 formatFiles($row);
 formatSrc($row['src'], $row['clid']);
 if (isset($row['did']) and strlen($row['did'])) {
     formatDst($row['did'], $row['dcontext'] . ' # ' . $row['dst']);
 } else {
     formatDst($row['dst'], $row['dcontext']);
 }
 if (isset($display_column['extension']) and $display_column['extension'] == 1) {
     formatDst($row['dst'], $row['dcontext']);
 }
 formatApp($row['lastapp'], $row['lastdata']);
 formatChannel($row['channel']);
 if (isset($display_column['clid']) and $display_column['clid'] == 1) {
     formatClid($row['clid']);
 }
 formatChannel($row['dstchannel']);
 formatDisposition($row['disposition'], $row['amaflags']);
 formatDuration($row['duration'], $row['billsec']);
 if (isset($display_column['billsec']) and $display_column['billsec'] == 1) {
     formatBillSec($row['billsec']);
 }
 formatUserField($row['userfield']);
 if (isset($display_column['accountcode']) and $display_column['accountcode'] == 1) {
     formatAccountCode($row['accountcode']);
 }
 if (isset($_REQUEST['use_callrates']) && $_REQUEST['use_callrates'] == 'true') {
     $rates = callrates($row['dst'], $row['billsec'], $callrate_csv_file);
     $rate_total += $rates[4];
     formatMoney($rates[4]);
Example #2
0
    echo "\t\t<th class=\"abndRcrd\">In</th>";
    echo "\t\t<th class=\"abndRcrd\">Out</th>";
    echo "\t</tr>";
    $count = 1;
    $color = "#e4ebf5";
    while ($rows = mysql_fetch_array($result, MYSQL_NUM)) {
        if ($color == "#ffffff") {
            $color = "#e4ebf5";
        } else {
            $color = "#ffffff";
        }
        echo "\t<tr class=\"abndRcrd\" style=\"background-color:" . $color . "\">";
        echo "\t\t<td class=\"abndRcrd\">" . $count . ".</td>";
        echo "\t\t<td class=\"abndRcrd\">" . $rows[1] . "/" . $rows[2] . "/" . $rows[0] . "</td>";
        echo "\t\t<td class=\"abndRcrd\">" . formatTime($rows[3], $rows[4], $rows[5]) . "</td>";
        echo "\t\t<td class=\"abndRcrd\">" . formatClid($rows[6]) . "</td>";
        echo "\t\t<td class=\"abndRcrd\">" . formatPhone($rows[7]) . "</td>";
        echo "\t\t<td class=\"abndRcrd\">" . $rows[8] . " seconds</td>";
        echo "\t\t<td class=\"abndRcrd\">" . "1st" . "</td>";
        echo "\t\t<td class=\"abndRcrd\">" . "1st" . "</td>";
        echo "\t</tr>";
        $count++;
    }
    //echo "	<tr>";
    //echo " Query: ".$query;
    //echo "	</tr>";
    echo "\t</table>";
} else {
    echo "<p>No records found</p>";
}
function formatPhone($num)