original_string: protected function headerCallBack($ch, $data){
          
          if (!is_null($data)) {
                  if (preg_match("~^HTTP/.*? 404~", $data)) {
                     
                      header(trim($data));
                      while (ob_get_level() > 0) {
                          ob_end_flush();
                      }
                  }
  
                  if (preg_match("~^Content-disposition~", $data)) {
                      header(str_replace("filename=", 'filename="', trim($data)) . '"');
                      while (ob_get_level() > 0) {
                          ob_end_flush();
                      }
                  }
  
                  if (preg_match("~^Content-Type~i", $data)) {
                      header(trim($data));
                      while (ob_get_level() > 0) {
                          ob_end_flush();
                      }
                  }
              }
              return strlen($data); //This means that we handled it, so cURL will keep processing
      }
code: protected function headerCallBack($ch, $data){
          
          if (!is_null($data)) {
                  if (preg_match("~^HTTP/.*? 404~", $data)) {
                     
                      header(trim($data));
                      while (ob_get_level() > 0) {
                          ob_end_flush();
                      }
                  }
  
                  if (preg_match("~^Content-disposition~", $data)) {
                      header(str_replace("filename=", 'filename="', trim($data)) . '"');
                      while (ob_get_level() > 0) {
                          ob_end_flush();
                      }
                  }
  
                  if (preg_match("~^Content-Type~i", $data)) {
                      header(trim($data));
                      while (ob_get_level() > 0) {
                          ob_end_flush();
                      }
                  }
              }
              return strlen($data); //This means that we handled it, so cURL will keep processing
      }
code_tokens: protected function headerCallBack ( $ ch , $ data ) { if ( ! is_null ( $ data ) ) { if ( preg_match ( "~^HTTP/.*? 404~" , $ data ) ) { header ( trim ( $ data ) ) ; while ( ob_get_level ( ) > 0 ) { ob_end_flush ( ) ; } } if ( preg_match ( "~^Content-disposition~" , $ data ) ) { header ( str_replace ( "filename=" , 'filename="' , trim ( $ data ) ) . '"' ) ; while ( ob_get_level ( ) > 0 ) { ob_end_flush ( ) ; } } if ( preg_match ( "~^Content-Type~i" , $ data ) ) { header ( trim ( $ data ) ) ; while ( ob_get_level ( ) > 0 ) { ob_end_flush ( ) ; } } } return strlen ( $ data ) ; //This means that we handled it, so cURL will keep processing }
docstring: Called to process headers from URL being proxied
  @param resource $ch The curl connection
  @param string $data The header data
  @return int length of the data from header
docstring_tokens: Called to process headers from URL being proxied