- Joined
- Mar 21, 2012
- Messages
- 5
- Reaction score
- 0
- Points
- 1
- Location
- Eagan, MN
- Your Mac's Specs
- Aluminum Unibody Macbook (Late 2008) 2.4 GHz Intel Core 2 Duo, 250GB HD, 6GB RAM, 10.8 Dev Preview
Can anyone tell me why the following code isn't working?
- (void)viewDidLoad
{
[super viewDidLoad];
NSString *website = @"http://www.rschooltoday.com/se3bin/clientgenie.cgi?schoolname=school1&statusFlag=goGenie&geniesite=1145&myButton=g5plugin&db=g1145_b16145";
NSURL *url = [NSURL URLWithString:website];
//NSURLRequest *requestUrl = [NSURLRequest requestWithURL:url];
//[webview loadRequest:requestUrl];
NSString *html = [webview stringByEvaluatingJavaScriptFromString:
@"getElementById(content_well_div_)"];
[self.webview loadHTMLString:html baseURL:url];
}
I'm trying to load just the central content of that teacher's page, but I don't have much experience with JS or HTML, this is just what I've been able to figure out from other forums and Wikipedia.
Thanks in advance!!
- (void)viewDidLoad
{
[super viewDidLoad];
NSString *website = @"http://www.rschooltoday.com/se3bin/clientgenie.cgi?schoolname=school1&statusFlag=goGenie&geniesite=1145&myButton=g5plugin&db=g1145_b16145";
NSURL *url = [NSURL URLWithString:website];
//NSURLRequest *requestUrl = [NSURLRequest requestWithURL:url];
//[webview loadRequest:requestUrl];
NSString *html = [webview stringByEvaluatingJavaScriptFromString:
@"getElementById(content_well_div_)"];
[self.webview loadHTMLString:html baseURL:url];
}
I'm trying to load just the central content of that teacher's page, but I don't have much experience with JS or HTML, this is just what I've been able to figure out from other forums and Wikipedia.
Thanks in advance!!