本文整理汇总了PHP中th_order_by函数的典型用法代码示例。如果您正苦于以下问题:PHP th_order_by函数的具体用法?PHP th_order_by怎么用?PHP th_order_by使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了th_order_by函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: th_order_by
echo "<td colspan='2' align='right'>\n";
//echo " <input type='button' class='btn' name='' alt='view' onclick=\"window.location='v_cdr_search.php'\" value='advanced'>\n";
echo "</td>\n";
echo "<td colspan='1' align='right'>\n";
echo "\t<input type='button' class='btn' name='' alt='view' onclick=\"window.location='v_cdr_search.php'\" value='advanced'> \n";
echo "\t<input type='submit' class='btn' name='submit' value='filter'>\n";
echo "</td>\n";
echo "</tr>";
echo "</table>";
echo "</form>";
}
echo "<table width='100%' border='0' cellpadding='0' cellspacing='0'>\n";
echo "<tr>\n";
echo "<th>Start</th>\n";
//echo th_order_by('start_stamp', 'Start', $order_by, $order);
echo th_order_by('caller_id_name', 'CID Name', $order_by, $order);
echo "<th>Source</th>\n";
//echo th_order_by('caller_id_number', 'Source', $order_by, $order);
echo "<th>Destination</th>\n";
//echo th_order_by('destination_number', 'Destination', $order_by, $order);
//echo th_order_by('context', 'Context', $order_by, $order);
//echo th_order_by('answer_stamp', 'Answer', $order_by, $order);
//echo th_order_by('end_stamp', 'End', $order_by, $order);
echo "<th>Duration</th>\n";
//echo th_order_by('duration', 'Duration', $order_by, $order);
echo "<th>Bill</th>\n";
//echo th_order_by('billsec', 'Bill', $order_by, $order);
echo "<th>Status</th>\n";
//echo th_order_by('hangup_cause', 'Status', $order_by, $order);
echo "<form method='post' action='v_cdr_csv.php'>";
echo "<td align='left' width='22'>\n";
示例2: check
echo "\t\t\t</td>\n";
echo "\t</tr>\n";
echo "</table>\n";
echo "<form name='frm' method='post' action='voicemail_delete.php'>\n";
echo "<table class='tr_hover' width='100%' border='0' cellpadding='0' cellspacing='0'>\n";
echo "<tr>\n";
if (permission_exists('voicemail_delete') && $num_rows > 0) {
echo "<th style='width: 30px; text-align: center; padding: 0px;'><input type='checkbox' id='chk_all' onchange=\"(this.checked) ? check('all') : check('none');\"></th>";
}
echo th_order_by('voicemail_id', $text['label-voicemail_id'], $order_by, $order);
echo th_order_by('voicemail_mail_to', $text['label-voicemail_mail_to'], $order_by, $order);
echo th_order_by('voicemail_file', $text['label-voicemail_file_attached'], $order_by, $order);
echo th_order_by('voicemail_local_after_email', $text['label-voicemail_local_after_email'], $order_by, $order);
echo "<th>" . $text['label-tools'] . "</th>\n";
echo th_order_by('voicemail_enabled', $text['label-voicemail_enabled'], $order_by, $order);
echo th_order_by('voicemail_description', $text['label-voicemail_description'], $order_by, $order);
echo "<td class='list_control_icon'>";
if (permission_exists('voicemail_add') || permission_exists('voicemail_edit')) {
echo "<a href='voicemail_edit.php' alt='" . $text['button-add'] . "'>" . $v_link_label_add . "</a>";
}
if (permission_exists('voicemail_delete') && $num_rows > 0) {
echo "<a href='javascript:void(0);' onclick=\"if (confirm('" . $text['confirm-delete'] . "')) { document.forms.frm.submit(); }\" alt='" . $text['button-delete'] . "'>" . $v_link_label_delete . "</a>";
}
echo "</td>\n";
echo "</tr>\n";
$c = 0;
$row_style["0"] = "row_style0";
$row_style["1"] = "row_style1";
if ($num_rows > 0) {
foreach ($voicemails as $row) {
$tr_link = permission_exists('voicemail_edit') ? "href='voicemail_edit.php?id=" . $row['voicemail_uuid'] . "'" : null;
示例3: count
}
$sql .= " limit {$rows_per_page} offset {$offset} ";
$prep_statement = $db->prepare(check_sql($sql));
$prep_statement->execute();
$result = $prep_statement->fetchAll(PDO::FETCH_NAMED);
$result_count = count($result);
unset($prep_statement, $sql);
$c = 0;
$row_style["0"] = "row_style0";
$row_style["1"] = "row_style1";
echo "<div align='center'>\n";
echo "<table width='100%' border='0' cellpadding='0' cellspacing='0'>\n";
echo "<tr>\n";
echo th_order_by('username', 'Username', $order_by, $order);
echo th_order_by('language', 'Language', $order_by, $order);
echo th_order_by('proficiency', 'Proficiency', $order_by, $order);
echo "<td align='right' width='42'>\n";
echo "\t<a href='v_fifo_agent_languages_edit.php' alt='add'>{$v_link_label_add}</a>\n";
//echo " <input type='button' class='btn' name='' alt='add' onclick=\"window.location='v_fifo_agent_languages_edit.php'\" value='+'>\n";
echo "</td>\n";
echo "<tr>\n";
if ($result_count == 0) {
//no results
} else {
//received results
foreach ($result as $row) {
//print_r( $row );
echo "<tr >\n";
echo "\t<td valign='top' class='" . $row_style[$c] . "'>" . $row[username] . "</td>\n";
echo "\t<td valign='top' class='" . $row_style[$c] . "'>" . $row[language] . "</td>\n";
echo "\t<td valign='top' class='" . $row_style[$c] . "'>" . $row[proficiency] . "</td>\n";
示例4: th_order_by
$c = 0;
$row_style["0"] = "row_style0";
$row_style["1"] = "row_style1";
echo "<table class='tr_hover' width='100%' border='0' cellpadding='0' cellspacing='0'>\n";
echo "<tr>\n";
//echo th_order_by('meeting_uuid', 'Meeting UUID', $order_by, $order);
//echo th_order_by('conference_uuid', 'Conference UUID', $order_by, $order);
//echo th_order_by('username', $text['label-username'], $order_by, $order);
//echo th_order_by('uuid', $text['label-uuid'], $order_by, $order);
echo th_order_by('caller_id_name', $text['label-caller-id-name'], $order_by, $order);
echo th_order_by('caller_id_number', $text['label-caller-id-number'], $order_by, $order);
echo th_order_by('moderator', $text['label-moderator'], $order_by, $order);
echo th_order_by('network_addr', $text['label-network-address'], $order_by, $order);
echo "<th>" . $text['label-time'] . "</th>\n";
echo th_order_by('start_epoch', $text['label-start'], $order_by, $order);
echo th_order_by('end_epoch', $text['label-end'], $order_by, $order);
if (permission_exists('conference_session_details')) {
echo "<td class='list_control_icon'> </td>\n";
}
echo "</tr>\n";
if ($result_count > 0) {
foreach ($result as $row) {
if (defined('TIME_24HR') && TIME_24HR == 1) {
$start_date = date("j M Y H:i:s", $row['start_epoch']);
$end_date = date("j M Y H:i:s", $row['end_epoch']);
} else {
$start_date = date("j M Y h:i:sa", $row['start_epoch']);
$end_date = date("j M Y h:i:sa", $row['end_epoch']);
}
$time_difference = '';
if (strlen($row['end_epoch']) > 0) {
示例5: count
$prep_statement->execute();
$result = $prep_statement->fetchAll(PDO::FETCH_NAMED);
$result_count = count($result);
unset($prep_statement, $sql);
$c = 0;
$row_style["0"] = "row_style0";
$row_style["1"] = "row_style1";
echo "<table class='tr_hover' width='100%' border='0' cellpadding='0' cellspacing='0'>\n";
echo "<tr>\n";
echo th_order_by('recording_name', $text['label-recording_name'], $order_by, $order);
if ($_SESSION['recordings']['storage_type']['text'] != 'base64') {
echo th_order_by('recording_filename', $text['label-file_name'], $order_by, $order);
echo "<th class='listhdr' style='text-align: center;' nowrap>" . $text['label-file-size'] . "</th>\n";
}
echo "<th class='listhdr' nowrap>" . $text['label-tools'] . "</th>\n";
echo th_order_by('recording_description', $text['label-description'], $order_by, $order);
echo "<td class='list_control_icons'> </td>\n";
echo "</tr>\n";
//calculate colspan for progress bar
$colspan = 5;
//max
if ($_SESSION['recordings']['storage_type']['text'] == 'base64') {
$colspan = $colspan - 2;
}
if (!(permission_exists('recording_edit') || permission_exists('recording_delete'))) {
$colspan = $colspan - 1;
}
if ($result_count > 0) {
foreach ($result as $row) {
//playback progress bar
if (permission_exists('recording_play')) {
示例6: count
$prep_statement->execute();
$result = $prep_statement->fetchAll(PDO::FETCH_NAMED);
$result_count = count($result);
unset($prep_statement, $sql);
$c = 0;
$row_style["0"] = "row_style0";
$row_style["1"] = "row_style1";
echo "<div align='center'>\n";
echo "<table width='100%' border='0' cellpadding='0' cellspacing='0'>\n";
echo "<tr>\n";
echo th_order_by('fifo_name', 'Queue Name', $order_by, $order);
echo th_order_by('agent_username', 'Username', $order_by, $order);
echo th_order_by('agent_priority', 'Agent Priority', $order_by, $order);
echo th_order_by('agent_status', 'Status', $order_by, $order);
echo th_order_by('agent_last_call', 'Last Call', $order_by, $order);
echo th_order_by('agent_contact_number', 'Contact Number', $order_by, $order);
echo "<td align='right' width='42'>\n";
//echo " <a href='v_fifo_agents_edit.php' alt='add'>$v_link_label_add</a>\n";
echo "</td>\n";
echo "<tr>\n";
if ($result_count == 0) {
//no results
} else {
//received results
foreach ($result as $row) {
//set the php variables
$agent_last_call = $row[agent_last_call];
date_default_timezone_set('America/Boise');
//format the last call time
$agent_last_call_desc = date("g:i:s a j M Y", $agent_last_call);
//get the agent status description
示例7: th_order_by
echo "<br />\n";
echo "</td>\n";
echo "</tr>\n";
//alternate the row style
$c = 0;
$row_style["0"] = "row_style0";
$row_style["1"] = "row_style1";
//show the data
echo "<table class='tr_hover' width='100%' border='0' cellpadding='0' cellspacing='0'>\n";
echo "<tr>\n";
if (permission_exists('user_all') && $_GET['showall'] == 'true') {
echo th_order_by('domain_name', $text['label-domain'], $order_by, $order, '', '', $param);
}
echo th_order_by('username', $text['label-username'], $order_by, $order);
echo "<th>" . $text['label-groups'] . "</th>\n";
echo th_order_by('user_enabled', $text['label-enabled'], $order_by, $order, '', '', $param);
echo "<td class='list_control_icons'>";
if (permission_exists('user_add')) {
if ($_SESSION['limit']['users']['numeric'] == '' || $_SESSION['limit']['users']['numeric'] != '' && $total_users < $_SESSION['limit']['users']['numeric']) {
echo "<a href='signup.php' alt='" . $text['button-add'] . "'>" . $v_link_label_add . "</a>";
}
}
echo "</td>\n";
echo "</tr>\n";
if ($user_count > 0) {
foreach ($users as $row) {
if (if_superadmin($superadmins, $row['user_uuid']) && !if_group("superadmin")) {
//hide
} else {
$tr_link = permission_exists('user_edit') ? "href='usersupdate.php?id=" . $row['user_uuid'] . "'" : null;
echo "<tr " . $tr_link . ">\n";
示例8: th_order_by
echo th_order_by('fax_result_code', $text['label-fax_result_code'], $order_by, $order, null, null, "&id=" . $fax_uuid);
echo th_order_by('fax_result_text', $text['label-fax_result_text'], $order_by, $order, null, null, "&id=" . $fax_uuid);
echo th_order_by('fax_file', $text['label-fax_file'], $order_by, $order, null, null, "&id=" . $fax_uuid);
echo th_order_by('fax_ecm_used', $text['label-fax_ecm_used'], $order_by, $order, null, null, "&id=" . $fax_uuid);
echo th_order_by('fax_local_station_id', $text['label-fax_local_station_id'], $order_by, $order, null, null, "&id=" . $fax_uuid);
//echo th_order_by('fax_document_transferred_pages', $text['label-fax_document_transferred_pages'], $order_by, $order);
//echo th_order_by('fax_document_total_pages', $text['label-fax_document_total_pages'], $order_by, $order);
//echo th_order_by('fax_image_resolution', $text['label-fax_image_resolution'], $order_by, $order);
//echo th_order_by('fax_image_size', $text['label-fax_image_size'], $order_by, $order);
echo th_order_by('fax_bad_rows', $text['label-fax_bad_rows'], $order_by, $order, null, null, "&id=" . $fax_uuid);
echo th_order_by('fax_transfer_rate', $text['label-fax_transfer_rate'], $order_by, $order, null, null, "&id=" . $fax_uuid);
echo th_order_by('fax_retry_attempts', $text['label-fax_retry_attempts'], $order_by, $order, null, null, "&id=" . $fax_uuid);
//echo th_order_by('fax_retry_limit', $text['label-fax_retry_limit'], $order_by, $order);
//echo th_order_by('fax_retry_sleep', $text['label-fax_retry_sleep'], $order_by, $order);
echo th_order_by('fax_uri', $text['label-fax_destination'], $order_by, $order, null, null, "&id=" . $fax_uuid);
echo th_order_by('fax_epoch', $text['label-fax_date'], $order_by, $order, null, null, "&id=" . $fax_uuid);
//echo th_order_by('fax_epoch', $text['label-fax_epoch'], $order_by, $order);
echo "<td class='list_control_icons'>";
echo " \n";
echo "</td>\n";
echo "</tr>\n";
if ($result_count > 0) {
foreach ($result as $row) {
$tr_link = "href='fax_log_view.php?id=" . $row['fax_log_uuid'] . "&fax_uuid=" . $fax_uuid . "'";
echo "<tr " . $tr_link . ">\n";
echo "\t<td valign='top' class='" . $row_style[$c] . "'>" . $row['fax_success'] . " </td>\n";
echo "\t<td valign='top' class='" . $row_style[$c] . "'>" . $row['fax_result_code'] . " </td>\n";
echo "\t<td valign='top' class='" . $row_style[$c] . "'>" . $row['fax_result_text'] . " </td>\n";
echo "\t<td valign='top' class='" . $row_style[$c] . "'>" . basename($row['fax_file']) . " </td>\n";
echo "\t<td valign='top' class='" . $row_style[$c] . "'>" . $row['fax_ecm_used'] . " </td>\n";
echo "\t<td valign='top' class='" . $row_style[$c] . "'>" . $row['fax_local_station_id'] . " </td>\n";
示例9: count
}
$sql .= "limit {$rows_per_page} offset {$offset} ";
$prep_statement = $db->prepare(check_sql($sql));
$prep_statement->execute();
$result = $prep_statement->fetchAll(PDO::FETCH_NAMED);
$result_count = count($result);
unset($prep_statement, $sql);
$c = 0;
$row_style["0"] = "row_style0";
$row_style["1"] = "row_style1";
echo "<table class='tr_hover' width='100%' border='0' cellpadding='0' cellspacing='0'>\n";
echo "<tr>\n";
echo th_order_by('node_type', $text['label-node_type'], $order_by, $order);
echo th_order_by('node_cidr', $text['label-node_cidr'], $order_by, $order);
echo th_order_by('node_domain', $text['label-node_domain'], $order_by, $order);
echo th_order_by('node_description', $text['label-node_description'], $order_by, $order);
echo "<td class='list_control_icons'>";
if (permission_exists('access_control_node_add')) {
echo "<a href='access_control_node_edit.php?access_control_uuid=" . $_GET['id'] . "' alt='" . $text['button-add'] . "'>{$v_link_label_add}</a>";
} else {
echo " \n";
}
echo "</td>\n";
echo "<tr>\n";
if ($result_count > 0) {
foreach ($result as $row) {
if (permission_exists('access_control_node_edit')) {
$tr_link = "href='access_control_node_edit.php?access_control_uuid=" . $row['access_control_uuid'] . "&id=" . $row['access_control_node_uuid'] . "'";
}
echo "<tr " . $tr_link . ">\n";
echo "\t<td valign='top' class='" . $row_style[$c] . "'>" . $row['node_type'] . " </td>\n";
示例10: th_order_by
echo "\t<tr>\n";
echo "\t\t<td width='50%' align='left' nowrap='nowrap'><b>" . $text['title-conference_control_details'] . "</b></td>\n";
//echo " <form method='get' action=''>\n";
//echo " <td width='50%' style='vertical-align: top; text-align: right; white-space: nowrap;'>\n";
//echo " <input type='text' class='txt' style='width: 150px' name='search' id='search' value='".$search."'>\n";
//echo " <input type='submit' class='btn' name='submit' value='".$text['button-search']."'>\n";
//echo " </td>\n";
//echo " </form>\n";
echo "\t</tr>\n";
echo "</table>\n";
echo "<table class='tr_hover' width='100%' border='0' cellpadding='0' cellspacing='0'>\n";
echo "<tr>\n";
echo th_order_by('control_digits', $text['label-control_digits'], $order_by, $order);
echo th_order_by('control_action', $text['label-control_action'], $order_by, $order);
echo th_order_by('control_data', $text['label-control_data'], $order_by, $order);
echo th_order_by('control_enabled', $text['label-control_enabled'], $order_by, $order);
echo "<td class='list_control_icons'>";
if (permission_exists('conference_control_detail_add')) {
echo "<a href='conference_control_detail_edit.php?conference_control_uuid=" . $_GET['id'] . "' alt='" . $text['button-add'] . "'>{$v_link_label_add}</a>";
} else {
echo " \n";
}
echo "</td>\n";
echo "<tr>\n";
if (is_array($result)) {
foreach ($result as $row) {
if (permission_exists('conference_control_detail_edit')) {
$tr_link = "href='conference_control_detail_edit.php?conference_control_uuid=" . $row['conference_control_uuid'] . "&id=" . $row['conference_control_detail_uuid'] . "'";
}
echo "<tr " . $tr_link . ">\n";
echo "\t<td valign='top' class='" . $row_style[$c] . "'>" . $row['control_digits'] . " </td>\n";
示例11: th_order_by
echo th_order_by('tta', $text['label-tta'], $order_by, $order, null, "style='text-align: right;'", $param);
echo th_order_by('duration', $text['label-duration'], $order_by, $order, null, "style='text-align: center;'", $param);
if (file_exists($_SERVER["PROJECT_ROOT"] . "/app/billing/app_config.php")) {
echo "<th>" . $text['label-price'] . "</th>\n";
$col_count++;
}
if (permission_exists('xml_cdr_pdd')) {
echo th_order_by('pdd_ms', 'PDD', $order_by, $order, null, "style='text-align: right;'", $param);
$col_count++;
}
if (permission_exists('xml_cdr_mos')) {
echo th_order_by('rtp_audio_in_mos', 'MOS', $order_by, $order, null, "style='text-align: center;'", $param);
$col_count++;
}
if (if_group("admin") || if_group("superadmin") || if_group("cdr")) {
echo th_order_by('hangup_cause', $text['label-hangup_cause'], $order_by, $order, null, null, $param);
} else {
echo "<th>" . $text['label-status'] . "</th>\n";
}
if (if_group("admin") || if_group("superadmin") || if_group("cdr")) {
echo "<td class='list_control_icon'>";
if (permission_exists('xml_cdr_delete') && $result_count > 0) {
echo "<a href='javascript:void(0);' onclick=\"if (confirm('" . $text['confirm-delete'] . "')) { document.forms.frm.submit(); }\" alt='" . $text['button-delete'] . "'>" . $v_link_label_delete . "</a>";
}
echo "</td>\n";
$col_count++;
}
echo "</tr>\n";
if (file_exists($_SERVER["PROJECT_ROOT"] . "/app/billing/app_config.php")) {
require_once "app/billing/resources/functions/rating.php";
require_once "resources/classes/database.php";
示例12: check
$c = 0;
$row_style["0"] = "row_style0";
$row_style["1"] = "row_style1";
echo "<form name='frm_delete' method='post' action='time_condition_delete.php'>\n";
echo "<input type='hidden' name='app_uuid' value='" . $app_uuid . "'>\n";
echo "<table class='tr_hover' width='100%' border='0' cellpadding='0' cellspacing='0'>\n";
echo "<tr>\n";
if (permission_exists('dialplan_delete') && $result_count > 0) {
echo "<th style='text-align: center;' style='text-align: center; padding: 3px 0px 0px 0px;' width='1'><input type='checkbox' onchange=\"(this.checked) ? check('all') : check('none');\"></th>";
}
echo th_order_by('dialplan_name', $text['label-name'], $order_by, $order, $app_uuid, null, $search != '' ? "search=" . $search : null);
echo th_order_by('dialplan_number', $text['label-number'], $order_by, $order, $app_uuid, null, $search != '' ? "search=" . $search : null);
echo th_order_by('dialplan_context', $text['label-context'], $order_by, $order, $app_uuid, null, $search != '' ? "search=" . $search : null);
echo th_order_by('dialplan_order', $text['label-order'], $order_by, $order, $app_uuid, "style='text-align: center;'", $search != '' ? "search=" . $search : null);
echo th_order_by('dialplan_enabled', $text['label-enabled'], $order_by, $order, $app_uuid, "style='text-align: center;'", $search != '' ? "search=" . $search : null);
echo th_order_by('dialplan_description', $text['label-description'], $order_by, $order, $app_uuid, null, $search != '' ? "search=" . $search : null);
echo "<td class='list_control_icons'>";
if (permission_exists('time_condition_add')) {
echo "<a href='" . PROJECT_PATH . "/app/time_conditions/time_condition_edit.php' alt='" . $text['button-add'] . "'>{$v_link_label_add}</a>";
}
if (permission_exists('time_condition_delete') && $result_count > 0) {
echo "<a href='javascript:void(0);' onclick=\"if (confirm('" . $text['confirm-delete'] . "')) { document.forms.frm_delete.submit(); }\" alt='" . $text['button-delete'] . "'>" . $v_link_label_delete . "</a>";
}
echo "</td>\n";
echo "</tr>\n";
if ($result_count > 0) {
foreach ($result as $row) {
$app_uuid = $row['app_uuid'];
$tr_link = "href='" . PROJECT_PATH . "/app/time_conditions/time_condition_edit.php?id=" . $row['dialplan_uuid'] . ($app_uuid != '' ? "&app_uuid=" . $app_uuid : null) . "'";
echo "<tr " . $tr_link . ">\n";
if (permission_exists("time_condition_delete")) {
示例13: count
$prep_statement->execute();
$result = $prep_statement->fetchAll();
$result_count = count($result);
unset($prep_statement, $sql);
//table headers
$c = 0;
$row_style["0"] = "row_style0";
$row_style["1"] = "row_style1";
echo "<table class='tr_hover' width='100%' border='0' cellpadding='0' cellspacing='0'>\n";
echo "<tr>\n";
echo th_order_by('call_block_number', $text['label-number'], $order_by, $order);
echo th_order_by('call_block_name', $text['label-name'], $order_by, $order);
echo th_order_by('call_block_count', $text['label-count'], $order_by, $order, '', "style='text-align: center;'");
echo th_order_by('date_added', $text['label-date-added'], $order_by, $order);
echo th_order_by('call_block_action', $text['label-action'], $order_by, $order);
echo th_order_by('call_block_enabled', $text['label-enabled'], $order_by, $order);
echo "<td class='list_control_icons'>";
if (permission_exists('call_block_add')) {
echo "<a href='call_block_edit.php' alt='" . $text['button-add'] . "'>{$v_link_label_add}</a>";
}
echo "</td>\n";
echo "</tr>\n";
//show the results
if ($result_count > 0) {
foreach ($result as $row) {
$tr_link = permission_exists('call_block_edit') ? "href='call_block_edit.php?id=" . $row['call_block_uuid'] . "'" : null;
echo "<tr " . $tr_link . ">\n";
echo "\t<td valign='top' class='" . $row_style[$c] . "'>";
if (permission_exists('call_block_edit')) {
echo "<a href='call_block_edit.php?id=" . $row['call_block_uuid'] . "'>" . $row['call_block_number'] . "</a>";
} else {
示例14: count
}
//echo $sql;
$prep_statement = $db->prepare(check_sql($sql));
$prep_statement->execute();
$result = $prep_statement->fetchAll(PDO::FETCH_NAMED);
$result_count = count($result);
$c = 0;
$row_style["0"] = "row_style0";
$row_style["1"] = "row_style1";
echo "<table class='tr_hover' width='100%' border='0' cellpadding='2' cellspacing='0'>\n";
echo "<tr>";
echo th_order_by('rss_title', $text['label-title'], $order_by, $order);
echo th_order_by('rss_link', $text['label-link'], $order_by, $order);
//echo th_order_by('rss_sub_category', 'Template', $order_by, $order);
echo th_order_by('rss_group', $text['label-group'], $order_by, $order);
echo th_order_by('rss_order', $text['label-order'], $order_by, $order, '', "style='text-align: center;'");
if ($result_count == 0) {
//no results
echo "<td class='list_control_icons'>\n";
} else {
echo "<td class='list_control_icons'>\n";
}
echo "\t<a href='rssadd.php' alt='add'>{$v_link_label_add}</a>\n";
echo "</td>\n";
echo "</tr>";
if ($result_count > 0) {
foreach ($result as $row) {
//print_r( $row );
$tr_link = "href='rssupdate.php?rss_uuid=" . $row[rss_uuid] . "'";
echo "<tr " . $tr_link . ">\n";
//echo "<td valign='top'><a href='rssupdate.php?rss_uuid=".$row[rss_uuid]."'>".$row[rss_uuid]."</a></td>";
示例15: count
}
$sql .= "limit {$rows_per_page} offset {$offset} ";
$prep_statement = $db->prepare(check_sql($sql));
$prep_statement->execute();
$result = $prep_statement->fetchAll(PDO::FETCH_NAMED);
$result_count = count($result);
unset($prep_statement, $sql);
$c = 0;
$row_style["0"] = "row_style0";
$row_style["1"] = "row_style1";
echo "<table class='tr_hover' width='100%' border='0' cellpadding='0' cellspacing='0'>\n";
echo "<tr>\n";
echo th_order_by('database_type', $text['label-type'], $order_by, $order);
echo th_order_by('database_host', $text['label-host'], $order_by, $order);
echo th_order_by('database_name', $text['label-name'], $order_by, $order);
echo th_order_by('database_description', $text['label-description'], $order_by, $order);
echo "<td class='list_control_icons' style='width: 25px;'> </td>\n";
echo "<tr>\n";
if ($result_count > 0) {
foreach ($result as $row) {
$tr_link = "href='exec.php?id=" . $row['database_uuid'] . "'";
echo "<tr " . $tr_link . ">\n";
echo "\t<td valign='top' class='" . $row_style[$c] . "'>" . $row['database_type'] . " </td>\n";
echo "\t<td valign='top' class='" . $row_style[$c] . "'>" . $row['database_host'] . " </td>\n";
echo "\t<td valign='top' class='" . $row_style[$c] . "'><a href='exec.php?id=" . $row['database_uuid'] . "'>" . $row['database_name'] . "</a> </td>\n";
echo "\t<td valign='top' class='row_stylebg'>" . $row['database_description'] . " </td>\n";
echo "\t<td class='list_control_icons' style='width: 25px;'>";
echo "\t\t<a href='exec.php?id=" . $row['database_uuid'] . "' alt='" . $text['button-edit'] . "'>" . $v_link_label_edit . "</a>\n";
echo "\t</td>\n";
echo "</tr>\n";
$c = $c == 0 ? 1 : 0;