Odd WebView Bhaviour
Odd WebView Bhaviour
- Subject: Odd WebView Bhaviour
- From: Thomas Davie <email@hidden>
- Date: Wed, 25 May 2005 20:16:17 +0100
Hi,
I've been trying to grab html output and display it in a web view,
but nothing loads, I've confirmed that it should by logging th URL
and trying to view it in safari - which displays the expected output.
- (IBAction)search:(id)sender
{
NSString *hoogleBin = [[NSBundle mainBundle]
pathForResource:@"xhoogle"
ofType:@""];
NSString *searchString = [self quoteArrows:[sender stringValue]];
NSString *hoogleDir = [hoogleBin
stringByDeletingLastPathComponent];
NSURL *hoogleOutURL = [NSURL fileURLWithPath:
[hoogleDir stringByAppendingPathComponent:@"temp.html"]];
NSURLRequest *hoogleOutReq = [NSURLRequest
requestWithURL:hoogleOutURL];
[spinner animate:self];
[spinner setHidden:NO];
NSTask *hoogleSearch = [[NSTask alloc] init];
[hoogleSearch setLaunchPath:hoogleBin];
[hoogleSearch setCurrentDirectoryPath:hoogleDir];
[hoogleSearch setArguments:[NSArray arrayWithObject:searchString]];
[hoogleSearch launch];
while ([hoogleSearch isRunning]) {}
[hoogleSearch release];
[[resultsView mainFrame] loadRequest:hoogleOutReq];
[spinner setHidden:YES];
[spinner stopAnimation:self];
}
Bob
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden