You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Vladimir Nikolic asked if we could have another Faster_Request class method called getRequest(). It would use $_GET or $_POST, depending on whether the server received a POST request or not. Note we don't want to use $_REQUEST because it has a problem, as spelled out here:
So, in a nutshell, the class method would sort of look like:
See if ($_POST). If so, then process with getPostedVar(). Otherwise, process with getVar().
I think this is a valid, very small thing to add, and which may help speed up development. I wouldn't personally use getRequest() except for testing purposes, and that's why it might help speed up development (because it speeds up testing).
The text was updated successfully, but these errors were encountered:
Vladimir Nikolic asked if we could have another Faster_Request class method called getRequest(). It would use $_GET or $_POST, depending on whether the server received a POST request or not. Note we don't want to use $_REQUEST because it has a problem, as spelled out here:
http://devlog.info/2010/02/04/why-php-request-array-is-dangerous/
So, in a nutshell, the class method would sort of look like:
See if ($_POST). If so, then process with getPostedVar(). Otherwise, process with getVar().
I think this is a valid, very small thing to add, and which may help speed up development. I wouldn't personally use getRequest() except for testing purposes, and that's why it might help speed up development (because it speeds up testing).
The text was updated successfully, but these errors were encountered: