當前位置: 首頁>>代碼示例>>PHP>>正文


PHP remove_get函數代碼示例

本文整理匯總了PHP中remove_get函數的典型用法代碼示例。如果您正苦於以下問題:PHP remove_get函數的具體用法?PHP remove_get怎麽用?PHP remove_get使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。


在下文中一共展示了remove_get函數的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: get_where_string

$per_page = 20;
$where = get_where_string($class_name);
$total_count = $class_name::count_all_where($where);
$pagination = new Pagination($page, $per_page, $total_count);
require_once LIB_PATH . DS . 'download' . DS . 'download_csv.php';
$sql = "SELECT * FROM {$table_name} ";
$sql .= " " . get_where_string($class_name);
if (isset($order_name)) {
    $sql .= " ORDER BY {$order_name} {$order_type} ";
}
$sql .= "LIMIT {$per_page} ";
$sql .= "OFFSET {$pagination->offset()}";
//echo "<p>$sql</p>";
//unset($_GET);
$result_class = $class_name::find_by_sql($sql);
$query_string = remove_get(array('view', 'page'));
$view_full_table = !empty($_GET) ? (int) $_GET["view"] : 0;
if ($view_full_table == 1) {
    $page_link_view = $class_name::$page_manage . $query_string . "page=" . u($page) . "&view=" . u(0);
    $page_link_text = $class_name::$page_name . " short view";
    //$add_view="&view=".u(1);
    $offset = "col-md-offset-2";
} else {
    $page_link_view = $class_name::$page_manage . $query_string . "page=" . u($page) . "&view=" . u(1);
    $page_link_text = $class_name::$page_name . " full view";
    $offset = '';
}
?>

<?php 
//var_dump($users)
開發者ID:kamy333,項目名稱:rajah,代碼行數:31,代碼來源:manage_TransportProgramming.php

示例2: display_table_head_new

 public static function display_table_head_new($long_short = 0, $edit = true)
 {
     // $query_string= urldecode($_SERVER['QUERY_STRING']);
     $query_string = remove_get(array('order_name', 'order_type', 'page'));
     if ($long_short == 1) {
         $table_field = static::$db_fields_table_display_full;
     } else {
         $table_field = static::$db_fields_table_display_short;
     }
     $output = "";
     $where = get_where_string(get_called_class());
     $found_count = static::count_all_where($where);
     $total_count = static::count_all();
     if ($found_count !== $total_count) {
         //            $output.="<b>Found records: <span style='color:blue;'> ".h($found_count)." of ".h($total_count)."</span></b> | ";
     }
     foreach ($_GET as $key => $val) {
         $key_clean = str_replace("_", " ", $key);
         $key_clean = ucfirst($key_clean);
         if (!empty($_GET[$key]) && !in_array($key, array('page', 'view'))) {
             //                $output.="<b>".h($key_clean)." <span style='color:blue;'> ".h(urldecode($_GET[$key]))."</span></b> | ";
         }
     }
     //        $output.= "<tr>";
     foreach ($table_field as $fieldname) {
         if (property_exists(new static(), $fieldname)) {
             $fieldname = str_replace("_", " ", $fieldname);
             $fieldname = ucfirst($fieldname);
             $output .= "<th class='text-center'>" . $fieldname . "</th>";
         }
     }
     if ($edit) {
         //            $output.= "<th colspan=\"1\" class=\"text-center\" style='vertical-align:middle;'>Actions</th>";
         $output .= "<th>Actions</th>";
         $output .= "<th></th>";
     }
     //        $output.= "</tr>";
     return $output;
 }
開發者ID:kamy333,項目名稱:rajah,代碼行數:39,代碼來源:database_object.php

示例3: get_where_string

$per_page = 20;
$where = get_where_string($class_name);
$total_count = $class_name::count_all_where($where);
$pagination = new Pagination($page, $per_page, $total_count);
require_once LIB_PATH . DS . 'download' . DS . 'download_csv.php';
$sql = "SELECT * FROM {$table_name} ";
$sql .= " " . get_where_string($class_name);
if (isset($order_name)) {
    $sql .= " ORDER BY {$order_name} {$order_type} ";
}
$sql .= "LIMIT {$per_page} ";
$sql .= "OFFSET {$pagination->offset()}";
//echo "<p>$sql</p>";
//unset($_GET);
$result_class = $class_name::find_by_sql($sql);
$query_string = remove_get(array('view', 'page', $class_name));
$view_full_table = !empty($_GET) ? (int) $_GET["view"] : 0;
if ($view_full_table == 1) {
    $page_link_view = $class_name::$page_manage . $query_string . "page=" . u($page) . "&view=" . u(0);
    $page_link_text = $class_name::$page_name . " short view";
    //$add_view="&view=".u(1);
    $offset = "col-md-offset-2";
} else {
    $page_link_view = $class_name::$page_manage . $query_string . "page=" . u($page) . "&view=" . u(1);
    $page_link_text = $class_name::$page_name . " full view";
    $offset = '';
}
?>

<?php 
//var_dump($users)
開發者ID:kamy333,項目名稱:rajah,代碼行數:31,代碼來源:manage_ajax.php

示例4: array

echo $home . "<br>";
$array = array();
foreach ($_GET as $key => $val) {
    if ($key == 'page') {
    } else {
        $url_decode = urldecode($val);
        $array[$key] = $url_decode;
    }
}
echo "<pre>";
print_r($array);
echo "</pre>";
$new = http_build_query($array);
echo "http_build_query: " . $new . "<br>";
echo "<hr>";
$a = remove_get(array('page'));
echo $a;
?>


<h4 class="text-center"><mark><a href="<?php 
echo $page_link;
?>
">my modele</a> </mark></h4>


<div class="col-md-7 col-md-offset-2 col-lg-7 col-lg-offset-2">


    <div class ="background_light_blue">
開發者ID:kamy333,項目名稱:rajah,代碼行數:30,代碼來源:0_modele3.php


注:本文中的remove_get函數示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。