'fail', 'err' => $response->code(), 'message' => $response->message(), ) ); } parent::flattenResponse($response); return serialize( array( 'stat' => 'ok', 'result' => $response ) ); } function getContentType() { return 'text/plain'; } } ?>