mirror of
https://bitbucket.org/jsuto/piler.git
synced 2024-11-08 02:01:58 +01:00
fixed a reference call bug in system/request.php
This commit is contained in:
parent
ec0f324601
commit
7cd3c12070
@ -10,33 +10,17 @@ class Request {
|
|||||||
|
|
||||||
|
|
||||||
public function __construct() {
|
public function __construct() {
|
||||||
$this->get =& $this->clean($_GET);
|
$this->get = $_GET;
|
||||||
$this->post =& $this->clean($_POST);
|
$this->post = $_POST;
|
||||||
$this->cookie =& $this->clean($_COOKIE);
|
$this->cookie = $_COOKIE;
|
||||||
$this->files =& $this->clean($_FILES);
|
$this->files = $_FILES;
|
||||||
$this->server =& $this->clean($_SERVER);
|
$this->server = $_SERVER;
|
||||||
|
|
||||||
if(isset($_SERVER['REQUEST_URI'])) {
|
if(isset($_SERVER['REQUEST_URI'])) {
|
||||||
$this->fixed_request_uri = preg_replace("/\/([\w]+)\.php\?{0,1}/", "", $_SERVER['REQUEST_URI']);
|
$this->fixed_request_uri = preg_replace("/\/([\w]+)\.php\?{0,1}/", "", $_SERVER['REQUEST_URI']);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public function clean($data) {
|
|
||||||
if (is_array($data)) {
|
|
||||||
foreach ($data as $key => $value) {
|
|
||||||
$data[$key] =& $this->clean($value);
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
//$data = htmlspecialchars($data, ENT_QUOTES, 'UTF-8');
|
|
||||||
}
|
|
||||||
|
|
||||||
return $data;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
?>
|
?>
|
||||||
|
Loading…
Reference in New Issue
Block a user