开发者

PHP Internal Arrays

I need to access the PHP internal representa开发者_StackOverflow中文版tion of the $_GET and $_POST arrays inside of my function for a particular page request. Is there a PHP internal representation of these arrays? Like for example $_GLOBAL is a representation of the internal array EG[Symbol_Table]. Otherwise is there any way to identify and access the GET and POST variables inside the symbol table and extract them?

In short I need all the variables that I would get from the $_POST and $_GET arrays but inside the Zend Engine. I am developing an extension that has a function with the format (input parameters, page) where the input parameters are all the variables declared by the php page. Is there any way to access this?


They're PG(http_globals)[TRACK_VARS_GET] and PG(http_globals)[TRACK_VARS_POST] respectively.


In the newer version (I assume after 5.3), you have to use stream "php://input" to access GET or POST data.

You can look into the implementation of file_get_contents function in php to see how to open and read a stream.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜