本文整理汇总了PHP中getGet函数的典型用法代码示例。如果您正苦于以下问题:PHP getGet函数的具体用法?PHP getGet怎么用?PHP getGet使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了getGet函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: __construct
/**
* constructor, init the parent-class
*/
public function __construct()
{
//find the params to use
$this->strFilename = urldecode(getGet("image"));
//avoid directory traversing
$this->strFilename = str_replace("../", "", $this->strFilename);
$this->intMaxHeight = (int) getGet("maxHeight");
if ($this->intMaxHeight < 0) {
$this->intMaxHeight = 0;
}
$this->intMaxWidth = (int) getGet("maxWidth");
if ($this->intMaxWidth < 0) {
$this->intMaxWidth = 0;
}
$this->intFixedHeight = (int) getGet("fixedHeight");
if ($this->intFixedHeight < 0 || $this->intFixedHeight > 2000) {
$this->intFixedHeight = 0;
}
$this->intFixedWidth = (int) getGet("fixedWidth");
if ($this->intFixedWidth < 0 || $this->intFixedWidth > 2000) {
$this->intFixedWidth = 0;
}
$this->intQuality = (int) getGet("quality");
if ($this->intQuality <= 0 || $this->intQuality > 100) {
$this->intQuality = 90;
}
$this->strSystemid = getGet("systemid");
$this->strElementId = getGet("elementid");
}
示例2: debugHelper
public function debugHelper()
{
echo "<pre>";
echo "<b>Kajona V4 Debug Subsystem</b>\n\n";
if (getGet("debugfile") != "") {
echo "Loading path for " . getGet("debugfile") . "\n";
$strPath = array_search(getGet("debugfile"), class_resourceloader::getInstance()->getFolderContent("/debug", array(".php")));
if ($strPath !== false) {
echo "Passing request to " . $strPath . "\n\n";
include _realpath_ . $strPath;
}
} else {
echo "Searching for debug-scripts available...\n";
$arrFiles = class_resourceloader::getInstance()->getFolderContent("/debug", array(".php"));
echo "<ul>";
foreach ($arrFiles as $strPath => $strOneFile) {
echo "<li><a href='?debugfile=" . $strOneFile . "' >" . $strOneFile . "</a> <br />" . $strPath . "</li>";
}
echo "</ul>";
}
$arrTimestampEnde = gettimeofday();
$intTimeUsed = ($arrTimestampEnde['sec'] * 1000000 + $arrTimestampEnde['usec'] - ($this->arrTimestampStart['sec'] * 1000000 + $this->arrTimestampStart['usec'])) / 1000000;
echo "\n\n<b>PHP-Time:</b> " . number_format($intTimeUsed, 6) . " sec \n";
echo "<b>Queries db/cachesize/cached/fired:</b> " . class_carrier::getInstance()->getObjDB()->getNumber() . "/" . class_carrier::getInstance()->getObjDB()->getCacheSize() . "/" . class_carrier::getInstance()->getObjDB()->getNumberCache() . "/" . (class_carrier::getInstance()->getObjDB()->getNumber() - class_carrier::getInstance()->getObjDB()->getNumberCache()) . "\n";
echo "<b>Templates cached:</b> " . class_carrier::getInstance()->getObjTemplate()->getNumberCacheSize() . " \n";
echo "<b>Memory/Max Memory:</b> " . bytesToString(memory_get_usage()) . "/" . bytesToString(memory_get_peak_usage()) . " \n";
echo "<b>Classes Loaded:</b> " . class_classloader::getInstance()->getIntNumberOfClassesLoaded() . " \n";
echo "<b>Cache requests/hits/saves/cachesize:</b> " . class_cache::getIntRequests() . "/" . class_cache::getIntHits() . "/" . class_cache::getIntSaves() . "/" . class_cache::getIntCachesize() . " \n";
echo "</pre>";
}
示例3: validateSinglePage
function validateSinglePage(class_module_pages_page $objPage)
{
$arrElements = class_module_pages_pageelement::getAllElementsOnPage($objPage->getSystemid());
$intI = 0;
$strPrevPlaceholder = "";
$strPrevLanguage = "";
foreach ($arrElements as $objOneElement) {
$strCurLevel = $objOneElement->getSystemid() . " - " . $objOneElement->getIntSort() . " - " . $objOneElement->getStrRecordClass() . " - " . $objOneElement->getStrDisplayName() . " - " . $objOneElement->getStrPlaceholder();
if ($strPrevPlaceholder != $objOneElement->getStrPlaceholder() || $strPrevLanguage != $objOneElement->getStrLanguage()) {
$intI = 1;
}
if ($objOneElement->getIntSort() != $intI) {
$strCurLevel = "<span style='color: red'>expected: " . $intI . ", got " . $objOneElement->getIntSort() . " @ " . $strCurLevel . "</span>";
if (getGet("doFix") != "") {
$strCurLevel .= "\nSetting new sort-id to " . $intI . "\n";
$strQuery = "UPDATE " . _dbprefix_ . "system SET system_sort = ? WHERE system_id = ? ";
class_carrier::getInstance()->getObjDB()->_pQuery($strQuery, array($intI, $objOneElement->getSystemid()));
}
} else {
$strCurLevel = "<span style='color: green'>" . $strCurLevel . "</span>";
}
echo "<div style='padding-left: 25px;'>" . $strCurLevel . "</div>";
$strPrevPlaceholder = $objOneElement->getStrPlaceholder();
$strPrevLanguage = $objOneElement->getStrLanguage();
$intI++;
}
}
示例4: __construct
public function __construct()
{
//start up system
$this->objTemplates = class_carrier::getInstance()->getObjTemplate();
$this->objLang = class_carrier::getInstance()->getObjLang();
//init session-support
$this->objSession = class_carrier::getInstance()->getObjSession();
//set a different language?
if (issetGet("language")) {
if (in_array(getGet("language"), explode(",", class_carrier::getInstance()->getObjConfig()->getConfig("adminlangs")))) {
$this->objLang->setStrTextLanguage(getGet("language"));
//and save to a cookie
$objCookie = new class_cookie();
$objCookie->setCookie("adminlanguage", getGet("language"));
}
} else {
//init correct text-file handling as in admins
$this->objLang->setStrTextLanguage($this->objSession->getAdminLanguage(true));
}
$this->STR_ORIG_CONFIG_FILE = class_resourceloader::getInstance()->getCorePathForModule("module_system") . "/module_system/system/config/config.php";
$this->STR_PROJECT_CONFIG_FILE = _realpath_ . "/project/system/config/config.php";
}
示例5: filesize
class_response_object::getInstance()->addHeader("Content-Length: " . filesize(_realpath_ . $objFile->getStrFilename()));
//End Session
$this->objSession->sessionClose();
class_response_object::getInstance()->sendHeaders();
//Loop the file
$ptrFile = @fopen(_realpath_ . $objFile->getStrFilename(), 'rb');
fpassthru($ptrFile);
@fclose($ptrFile);
ob_flush();
flush();
return "";
} else {
class_response_object::getInstance()->setStrStatusCode(class_http_statuscodes::SC_FORBIDDEN);
}
} else {
class_response_object::getInstance()->setStrStatusCode(class_http_statuscodes::SC_NOT_FOUND);
}
} else {
class_response_object::getInstance()->setStrStatusCode(class_http_statuscodes::SC_NOT_FOUND);
}
//if we reach up here, something gone wrong :/
class_response_object::getInstance()->setStrRedirectUrl(str_replace(array("_indexpath_", "&"), array(_indexpath_, "&"), class_link::getLinkPortalHref(class_module_system_setting::getConfigValue("_pages_errorpage_"))));
class_response_object::getInstance()->sendHeaders();
class_response_object::getInstance()->sendContent();
return "";
}
}
//Create a object
$objDownload = new class_download_manager(getGet("systemid"));
$objDownload->actionDownload();
class_core_eventdispatcher::getInstance()->notifyGenericListeners(class_system_eventidentifier::EVENT_SYSTEM_REQUEST_AFTERCONTENTSEND, array(class_request_entrypoint_enum::DOWNLOAD()));
示例6: getReport
/**
* @return string
*/
public function getReport()
{
$strReturn = "";
//showing a list using the pageview
$objArraySectionIterator = new class_array_section_iterator($this->getTopQueriesCount());
$objArraySectionIterator->setPageNumber((int) (getGet("pv") != "" ? getGet("pv") : 1));
$objArraySectionIterator->setArraySection($this->getTopQueries($objArraySectionIterator->calculateStartPos(), $objArraySectionIterator->calculateEndPos()));
$intI = 0;
$arrLogs = array();
$objUser = new class_module_user_user(class_session::getInstance()->getUserID());
foreach ($objArraySectionIterator as $intKey => $arrOneLog) {
if ($intI++ >= $objUser->getIntItemsPerPage()) {
break;
}
$arrLogs[$intKey][0] = $intI;
$arrLogs[$intKey][1] = $arrOneLog["search_log_query"];
$arrLogs[$intKey][2] = $arrOneLog["hits"];
}
//Create a data-table
$arrHeader = array();
$arrHeader[0] = "#";
$arrHeader[1] = $this->objLang->getLang("header_query", "search");
$arrHeader[2] = $this->objLang->getLang("header_amount", "search");
$strReturn .= $this->objToolkit->dataTable($arrHeader, $arrLogs);
$strReturn .= $this->objToolkit->getPageview($objArraySectionIterator, "stats", uniStrReplace("class_stats_report_", "", get_class($this)));
return $strReturn;
}
示例7: header
<?php
@(include 'utilities/all.php');
header("Content-Type: application/json");
checkGetParameter('title');
checkGetParameter('price');
checkGetParameter('description');
checkGetParameter('photo');
checkGetParameter('thumbnail');
checkGetParameter('fb_id');
checkGetParameter('cat_name');
$title = cleanString(getGet('title'));
$price = cleanString(getGet('price'));
$description = cleanString(getGet('description'));
$photo = cleanString(getGet('photo'));
$thumbnail = cleanString(getGet('thumbnail'));
$fb_id = cleanString(getGet('fb_id'));
$cat_name = cleanString(getGet('cat_name'));
$sql = "SELECT * FROM users, schools WHERE fb_id={$fb_id} AND users.school_id = schools.school_id";
$result = db_query($sql);
$row = mysql_fetch_array($result, MYSQL_ASSOC);
$school_id = $row['school_id'];
$user_name = $row['name'];
#TODO: Checking if the user has submitted the maximum number of items
$sql = "INSERT INTO items (item_title, item_price, item_description, item_photo, item_thumbnail, \n\tfb_id, cat_name, school_id, user_name)\n\t\tVALUES ('{$title}', {$price}, '{$description}', '{$photo}', '{$thumbnail}', {$fb_id}, \n\t'{$cat_name}', {$school_id}, '{$user_name}')";
$result = db_query($sql);
$out['success'] = true;
echo json_encode($out);
示例8: header
<?php
@(include 'utilities/all.php');
header("Content-Type: application/json");
$school = cleanString(getGet('school'));
$where = "WHERE 1 AND schools.school_id=users.school_id";
if ($school != '') {
$where .= " AND school_id={$school}";
}
$sql = "SELECT count(*) as num FROM users, schools {$where}";
#echo $sql;
$result = db_query($sql);
$arr = array();
$out = mysql_fetch_array($result, MYSQL_ASSOC);
echo json_encode($out);
示例9: define
<?php
/*"******************************************************************************************************
* (c) 2004-2006 by MulchProductions, www.mulchprod.de *
* (c) 2007-2015 by Kajona, www.kajona.de *
* Published under the GNU LGPL v2.1, see /system/licence_lgpl.txt *
*-------------------------------------------------------------------------------------------------------*
* $Id$ *
********************************************************************************************************/
//Determine the area to load
if (issetGet("admin") && getGet("admin") == 1) {
define("_admin_", true);
} else {
define("_admin_", false);
}
define("_autotesting_", false);
/**
* Class handling all requests to be served with xml
*
* @package module_system
*/
class class_xml
{
private static $bitRenderXmlHeader = true;
/**
* @var class_response_object
*/
public $objResponse;
/**
* Starts the processing of the requests, fetches params and passes control to the request dispatcher
* @return void
示例10: getGet
<?php
include 'utilities/all.php';
require_once 'utilities/facebook.php';
include 'm_facebook.php';
$isLoggedIn;
if (checkLogin($user)) {
$isLoggedIn = true;
} else {
$isLoggedIn = false;
}
$user_id = getGet('user_id');
if ($user_id == '') {
header("Location: index.php");
exit(0);
}
$param = array('userid' => $user_id);
$otheruser = extrabaon_api("GetUserDetails", $param);
@(include 'm_htmldoctype.php');
?>
<html>
<head>
<?php
@(include 'm_htmlhead-init.php');
?>
<title></title>
<meta property="fb:app_id" content="" />
<meta property="og:type" content="" />
<meta property="og:url" content="" />
<meta property="og:title" content="" />
示例11: getGet
<?php
require_once 'core.php';
require_once 'utility.php';
$name = getGet('name', '');
$team = getTeam("{$name}");
?>
<HEAD>
<TITLE>
<?php
if ($team) {
echo "NFL Team: {$name}";
} else {
echo "NFL Team Lookup";
}
?>
</TITLE>
<?php
echo $headBust;
?>
</HEAD>
<BODY BGCOLOR=WHITE>
<DIV ALIGN="CENTER">
<?php
if ($team) {
?>
<TABLE ALIGN="CENTER">
<TR><H1><?php
echo $name;
示例12: date
//新文件名
$new_file_name = date("YmdHis") . '_' . rand(10000, 99999) . '.' . $file_ext;
//移动文件
$file_path = $save_path . $new_file_name;
@chmod($file_path, 0644);
//修改目录权限(Linux)
if (move_uploaded_file($tmp_name, $file_path) === false) {
//开始移动
exit("返回错误: 上传文件失败。({$file_name})");
}
$file_url = $save_url . $new_file_name;
$fileName = uniqid('image', true) . $type;
echo "<a href=\"" . $file_url . "\" target=\"_blank\">原图[{$file_url}]</a><br />";
echo "所在目录 \"{$save_url}\"<br />";
echo "Stored in: " . $file_name . "<br />";
echo "MD5效验:" . getGet("access2008_File_md5") . "<br />";
echo "<br />上传成功!你选择的是<font color='#ff0000'>" . getPost("select") . "</font>--<font color='#0000ff'>" . getPost("select2") . "</font>";
if (getPost("access2008_box_info_max") != "") {
echo "<br />组件文件列表统计,总数量:" . getPost("access2008_box_info_max") . ",剩余:" . ((int) getPost("access2008_box_info_upload") - 1) . ",完成:" . ((int) getPost("access2008_box_info_over") + 1);
}
echo " <br />旋转角度:" . getPost("access2008_image_rotation");
}
function filekzm($a)
{
$c = strrchr($a, '.');
if ($c) {
return $c;
} else {
return '';
}
}
示例13: getRequest
/**
* POST or GET
*/
function getRequest($key, $default = null)
{
return filter_has_var(INPUT_POST, $key) ? getPost($key, $default) : getGet($key, $default);
}
示例14: header
<?php
@(include 'utilities/all.php');
header("Content-Type: application/json");
$school = cleanString(getGet('school'));
$category = cleanString(getGet('category'));
$query = cleanString(getGet('query'));
$where = "WHERE item_status=1";
if ($school != '') {
$where .= " AND school_id={$school} ";
}
if ($category != '') {
$where .= " AND cat_name='{$category}' ";
}
if ($query != '') {
$where .= " AND (item_title LIKE '%{$query}%' OR item_description LIKE '%{$query}%') ";
}
$sql = "SELECT count(*) as num FROM items {$where} ";
#echo $sql;
$result = db_query($sql);
$arr = array();
$out = mysql_fetch_array($result, MYSQL_ASSOC);
echo json_encode($out);
示例15: getGet
function getGet($key, $default = '')
{
return getGet($key, $default);
}