uiwebview

UIWebView won't load links with certificate (https:// prefix)

倖福魔咒の 提交于 2019-11-30 04:06:08
I know this has been asked before but I have looked at every answer (there aren't many) and none help me. The issue I am running into is dealing with certificates with my schools e-mail service. The links for the two e-mail services are here: Main school e-mail: https://marauder.millersville.edu/mail/index.pl Computer Science e-mail: https://cs.millersville.edu/cswebmail University student portal (Marauder Mail button on the right doesn't open when clicked in my UIWebView) http://myville.millersville.edu/ At first neither of the websites would load in my UIWebView using a standard NSURL and

UIWebview won't zoom even after setting scalesPageToFit to YES

我怕爱的太早我们不能终老 提交于 2019-11-30 04:00:54
I have a UIWebview that is loaded as a subview when a user selects a tab on a UISegmentedControl . For some reason, I can not get it to allow pinch/zooming . I set the following code in the viewDidLoad: method, so it should work. self.myWebView = [[[UIWebView alloc] initWithFrame:self.view.frame] autorelease]; self.myWebView.backgroundColor = [UIColor whiteColor]; self.myWebView.scalesPageToFit = YES; self.myWebView.autoresizingMask = (UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight); self.myWebView.delegate = self; [self.view addSubview: myWebView]; I tried loading a

Creating a good custom emoticon chat experience on iOS

≡放荡痞女 提交于 2019-11-30 03:52:39
I'm trying to come up with possible implementations for what is basically an expanding UITextView with the capability of typing inline images. There are literally dozens of open source projects I've seen that handle creation of labels with custom emoticons, UIWebViews that draw your images inline with text and so on, but none that don't run over the native UITextView behavior: Autocorrect Spelling Magnifying glass Selection tooltip and capability Double space for period The only app I've seen on the app store that gives a good, robust experience with typing custom emoticons is Viber. So the

Separate cookie storage for two (UIWebView or WKWebView)

空扰寡人 提交于 2019-11-30 03:35:54
问题 I want to login many accounts of same site in different webView . For example i have Tab Bar Controller that contains three view controllers and each view controllers contain webView . And for example i embed stackoverflow url for webView in every class. How user can login to different accounts at the same time using these three webView ? I've tried this but i can just login one user at a time. I have found that i need to create separate cookie for every UIWebView , but mostly answers are in

How do I get an image from the iOS photo library and display it in UIWebView

时光怂恿深爱的人放手 提交于 2019-11-30 03:04:54
I've seen a lot of examples where you use the UIImage for outputting an image. I would like the output to be set to a UIWebView because I want to put some additional HTML formatting around the image. I want to get the photo library to return the relative path of an image stored on the iOS device, so that the I can put that in the 'src' attribute of the 'img' HTML tag. Is this possible? Edit 1 I had to modify my code for what I wanted but this doesn't seem to work. - (void)imagePickerController:(UIImagePickerController *)picker didFinishPickingMediaWithInfo:(NSDictionary *)info { //Get Image

UIWebView stringByEvaluatingJavaScriptFromString

假装没事ソ 提交于 2019-11-30 02:46:02
I'm stuck on getting some pretty basic JS to run in my UIWebView. In the web view's delegate, I have : - (void)webViewDidFinishLoad:(UIWebView *)wView { NSString *someHTML = [wView stringByEvaluatingJavaScriptFromString:@"document.getElementsByClassName('box')[0]"]; NSString *allHTML = [wView stringByEvaluatingJavaScriptFromString:@"document.body.innerHTML"]; NSLog(@"someHTML: %@", someHTML); NSLog(@"allHTML: %@", allHTML); } but when the method is invoked, someHTML is nil while allHTML contains the entire body of the HTML in the webview. I've run the JS in the Safari JS console and it works

iOS Hiding tab bar in iOS 6 creates black bar (fix for iOS 6 breaks iOS 7!)

可紊 提交于 2019-11-30 02:32:18
I've got a tabbed application and in one tab there is a UIWebView . When I rotate the device to landscape I've made the UIWebView full screen while hiding the status and tab bar. I've got it working in iOS 6 - originally when rotating and hiding the tab bar it would leave a black space where the tab bar was, so the fHeight code fixes this. However, on iOS 6 it worked perfectly, but now it actually creates the black bar problem iOS 6 was having!! Any ideas for a workaround to this? Please see my edit below this - (void)willRotateToInterfaceOrientation:(UIInterfaceOrientation

Resize images in UIWebView to viewport size

孤人 提交于 2019-11-30 02:09:32
I'm displaying HTML with some images inside a UIWebView in my iPhone App. When the images are wider than the viewport of the iPhone I get horizontal scrollers which I don't want because its mostly about the text not the images. Is there a way to resize images displayed inside the UIWebView according to the width (best: even if the device is rotated)? If you want the maximum width to be the width of the webView, use the max-width CSS property. max-width: 100%; width: auto; height: auto; If the image is inside a UIWebView you could try using css to size them to 100%? Something like . . . <img

How to get HTTP headers

别说谁变了你拦得住时间么 提交于 2019-11-30 01:58:09
How do you retrieve all HTTP headers from a NSURLRequest in Objective-C? Harish Saran This falls under the easy, but not obvious class of iPhone programming problems. Worthy of a quick post: The headers for an HTTP connection are included in the NSHTTPURLResponse class. If you have an NSHTTPURLResponse variable you can easily get the headers out as a NSDictionary by sending the allHeaderFields message. For synchronous requests — not recommended, because they block — it’s easy to populate an NSHTTPURLResponse : NSURL *url = [NSURL URLWithString:@"http://www.mobileorchard.com"]; NSURLRequest

iPhone UIWebView - Can auto complete be turned off on a input text field?

不打扰是莪最后的温柔 提交于 2019-11-30 01:22:02
问题 I've searched high & low for an answer on this and I can't seem to find an answer or anybody else having the same issue. Hope some one can assist? I have a web page for signup which I'm viewing in an iPhone UIWebView. A user is asking if we can stop capitalization on the first letter of the email address being entered. I thought this didn't matter, but apparently it can for the local-part on some email systems (apparently it's only the domain that is only case insensitive). It seems