Changeset 7266 for sandbox/newExpressoMail/prototype/Sync.php
- Timestamp:
- 09/21/12 10:11:56 (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sandbox/newExpressoMail/prototype/Sync.php
r6328 r7266 4 4 $accept = $_SERVER["HTTP_ACCEPT"]; 5 5 6 if(!function_exists('getRealREQUEST')) 7 { 8 function getRealREQUEST() { 9 $vars = array(); 10 11 if(isset($_SERVER['REDIRECT_QUERY_STRING'])) 12 $input = $_SERVER['REDIRECT_QUERY_STRING']; 13 14 if(!empty($input)){ 15 $pairs = explode("&", $input); 16 foreach ($pairs as $pair) { 17 $nv = explode("=", $pair); 18 19 $name = urldecode($nv[0]); 20 $nameSanitize = preg_replace('/([^\[]*)\[.*$/','$1',$name); 21 22 $nameMatched = str_replace('.','_',$nameSanitize); 23 $nameMatched = str_replace(' ','_',$nameMatched); 24 25 $vars[$nameSanitize] = $_REQUEST[$nameMatched]; 26 } 27 } 28 29 $input = file_get_contents("php://input"); 30 if(!empty($input)){ 31 $pairs = explode("&", $input); 32 foreach ($pairs as $pair) { 33 $nv = explode("=", $pair); 34 35 $name = urldecode($nv[0]); 36 $nameSanitize = preg_replace('/([^\[]*)\[.*$/','$1',$name); 37 38 $nameMatched = str_replace('.','_',$nameSanitize); 39 $nameMatched = str_replace(' ','_',$nameMatched); 40 41 $vars[$nameSanitize] = $_REQUEST[$nameMatched]; 42 } 43 } 44 45 return $vars; 46 } 47 } 48 6 49 if( !isset( $args ) ) 7 parse_str( file_get_contents('php://input'), $args);50 $args = getRealREQUEST(); 8 51 9 52 if(!function_exists('parseURI'))
Note: See TracChangeset
for help on using the changeset viewer.