summaryrefslogtreecommitdiff
path: root/framework/Web/THttpRequest.php
diff options
context:
space:
mode:
authorxue <>2005-11-16 22:32:52 +0000
committerxue <>2005-11-16 22:32:52 +0000
commit6c1b05deafd9940da5d473800032558df90b118e (patch)
tree3435de08a595fab3ca71ed41f3a88cc9ab6e2995 /framework/Web/THttpRequest.php
parent65acec4f65ddefcb3e9f9762d958be0539f3f71a (diff)
Key modules are now using registered to application rather than using reserved module names.
Diffstat (limited to 'framework/Web/THttpRequest.php')
-rw-r--r--framework/Web/THttpRequest.php45
1 files changed, 23 insertions, 22 deletions
diff --git a/framework/Web/THttpRequest.php b/framework/Web/THttpRequest.php
index f87111ba..9be0db8a 100644
--- a/framework/Web/THttpRequest.php
+++ b/framework/Web/THttpRequest.php
@@ -68,6 +68,28 @@ class THttpRequest extends TComponent implements IModule
*/
public function __construct()
{
+ }
+
+ /**
+ * Strips slashes from input data.
+ * This method is applied when magic quotes is enabled.
+ * Do not call this method.
+ * @param mixed input data to be processed
+ * @param mixed processed data
+ */
+ public function stripSlashes(&$data)
+ {
+ return is_array($data)?array_map(array($this,'stripSlashes'),$data):stripslashes($data);
+ }
+
+ /**
+ * Initializes the module.
+ * This method is required by IModule and is invoked by application.
+ * @param IApplication application
+ * @param TXmlElement module configuration
+ */
+ public function init($application,$config)
+ {
// Info about server variables:
// PHP_SELF contains real URI (w/ path info, w/o query string)
// SCRIPT_NAME is the real URI for the requested script (w/o path info and query string)
@@ -101,29 +123,8 @@ class THttpRequest extends TComponent implements IModule
$this->_items=new TMap(array_merge($_POST,$_GET));
$this->resolveRequest();
- }
-
- /**
- * Strips slashes from input data.
- * This method is applied when magic quotes is enabled.
- * Do not call this method.
- * @param mixed input data to be processed
- * @param mixed processed data
- */
- public function stripSlashes(&$data)
- {
- return is_array($data)?array_map(array($this,'stripSlashes'),$data):stripslashes($data);
- }
-
- /**
- * Initializes the module.
- * This method is required by IModule and is invoked by application.
- * @param IApplication application
- * @param TXmlElement module configuration
- */
- public function init($application,$config)
- {
$this->_initialized=true;
+ $application->setRequest($this);
}
/**