]> gitweb.fluxo.info Git - lorea/elgg.git/commitdiff
Fixes #2548 do not need include_post_data() because of changes to rewrite rules
authorcash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>
Sat, 22 Jan 2011 22:50:35 +0000 (22:50 +0000)
committercash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>
Sat, 22 Jan 2011 22:50:35 +0000 (22:50 +0000)
git-svn-id: http://code.elgg.org/elgg/trunk@7908 36083f99-b078-4883-b0ff-0f9b5a30f544

engine/lib/web_services.php

index 33f413c5cf1d8fce351581e819e4999e01575631..f39f5aef1a35de1516d0f6e3ce30c586b4c5c119 100644 (file)
@@ -162,12 +162,6 @@ function authenticate_method($method) {
                throw new APIException(elgg_echo('APIException:MethodCallNotImplemented', array($method)));
        }
 
-       // make sure that POST variables are available if needed
-       // @todo this may not be needed anymore due to adding %{QUERY_STRING} in .htaccess in 1.7.2
-       if (get_call_method() === 'POST' && empty($_POST)) {
-               include_post_data();
-       }
-
        // check API authentication if required
        if ($API_METHODS[$method]["require_api_auth"] == true) {
                $api_pam = new ElggPAM('api');
@@ -313,37 +307,6 @@ function get_post_data() {
        return $postdata;
 }
 
-/**
- * This fixes the post parameters that are munged due to page handler
- *
- * @since 1.7.0
- *
- * @return void
- */
-function include_post_data() {
-
-       $postdata = get_post_data();
-
-       if (isset($postdata)) {
-               $query_arr = elgg_parse_str($postdata);
-
-               // grrrr... magic quotes is turned on so we need to strip slashes
-               if (ini_get_bool('magic_quotes_gpc')) {
-                       if (function_exists('stripslashes_deep')) {
-                               // defined in input.php to handle magic quotes
-                               $query_arr = stripslashes_deep($query_arr);
-                       }
-               }
-
-               if (is_array($query_arr)) {
-                       foreach ($query_arr as $name => $val) {
-                               set_input($name, $val);
-                       }
-               }
-
-       }
-}
-
 /**
  * Verify that the required parameters are present
  *