WordPress.org

Make WordPress Core

Ticket #4248: 4248.diff

File 4248.diff, 626 bytes (added by rob1n, 11 years ago)
  • xmlrpc.php

     
    55// Some browser-embedded clients send cookies. We don't want them.
    66$_COOKIE = array();
    77
     8// A bug in PHP < 5.2.2 makes $HTTP_RAW_POST_DATA not set by default,
     9// but we can do it ourself.
     10if ( !isset( $HTTP_RAW_POST_DATA ) ) {
     11        $HTTP_RAW_POST_DATA = file_get_contents( 'php://input' );
     12}
     13
    814# fix for mozBlog and other cases where '<?xml' isn't on the very first line
    915if ( isset($HTTP_RAW_POST_DATA) )
    1016        $HTTP_RAW_POST_DATA = trim($HTTP_RAW_POST_DATA);