diff -r 8267d5c429c4 -r 84c2d38f924c BLIP/BLIPRequest.m --- a/BLIP/BLIPRequest.m Sat May 24 13:26:02 2008 -0700 +++ b/BLIP/BLIPRequest.m Wed Jun 04 17:11:20 2008 -0700 @@ -103,9 +103,25 @@ return _response != nil; } -- (void) respondWithData: (NSData*)data {self.response.body = data; [self.response send];} -- (void) respondWithString: (NSString*)string {[self respondWithData: [string dataUsingEncoding: NSUTF8StringEncoding]];} -- (void) respondWithError: (NSError*)error {self.response.error = error; [self.response send];} +- (void) respondWithData: (NSData*)data contentType: (NSString*)contentType +{ + BLIPResponse *response = self.response; + response.body = data; + response.contentType = contentType; + [response send]; +} + +- (void) respondWithString: (NSString*)string +{ + [self respondWithData: [string dataUsingEncoding: NSUTF8StringEncoding] + contentType: @"text/plain; charset=UTF-8"]; +} + +- (void) respondWithError: (NSError*)error +{ + self.response.error = error; + [self.response send]; +} - (void) respondWithErrorCode: (int)errorCode message: (NSString*)errorMessage {