Search Results

Search found 472 results on 19 pages for 'uiwebview'.

Page 4/19 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • iPhone UIWebView becomeFirstResponder

    - by user505618
    I have an UIWebView with an <input type="text"/> html element in it. I want to focus the input element in the html and show the keyboard on the iPhone programmatically, without tapping the screen. I've tried the following: set the focus from JavaScript (in this case the onFocus JS event will fire but the keyboard won't show up) [webView becomeFirstresponder] (returns NO) set the first subview of the webView to be the firstResponder (returns NO) subclass UIWebView to return YES to canBecomeFirstResponder: (nothing happens) I'm trying to find the solution since yesterday but I couldn't find it. Please help.

    Read the article

  • Pull down UIToolbar above UIWebView inside UIScrollView

    - by Nick VanderPyle
    I'd like to display a toolbar above a UIWebView but hide the toolbar until the person "pulls it down". The same functionality can be seen in Safari on the iPhone. When the page loads, the toolbar containing the address is hidden. You must pull it down. In Safari it's possible to scroll up and eventually see the toolbar or scroll down through the page contents. I've tried placing a UIToolbar and UIWebView inside a UIScrollView but it didn't work. I've tried setting the UIScrollView to the size of the toolbar and webview combined, but that didn't work. - (void)viewDidLoad{ CGSize size = CGSizeMake(webView.frame.size.width, toolBar.frame.size.height + webView.frame.size.height); [scrollView setContentSize:size]; } How should I go about doing this?

    Read the article

  • How to insert HTML into a UIWebView

    - by Mohan Gulati
    I have HTML Content which was being displayed in a text. The next iteration of my app is display the HTML contents into a UIWebView. So I basically replaced my UITextView with UIWebView. However I could not figure out how to inset my HTML snippit into the view. It seems to need a URLRequest which I do not want. I have already stored the HTML content in memory and want to load and display it from memory. Any ideas how I should proceed?

    Read the article

  • UIWebView loads a local file for a long time

    - by Knodel
    I have a UIWebView which loads .rtfd.zip files like this: -(void)viewWillAppear:(BOOL)animated { self.title=@"Title"; if(rowPosledovatelnosti==0) { [self loadFile:@"PosledovatelnostiObzie.rtfd.zip"]; } if(rowPosledovatelnosti==1) { [self loadFile:@"Arifmeticheskaya.rtfd.zip"]; } if(rowPosledovatelnosti==2) { [self loadFile:@"Svojstva_Arifmeticheskoj.rtfd.zip"]; } if(rowPosledovatelnosti==3) { [self loadFile:@"Geometricheskaya.rtfd.zip"]; } if(rowPosledovatelnosti==4) { [self loadFile:@"Predel_Posledovatelnosti.rtfd.zip"]; } if(rowPosledovatelnosti==5) { [self loadFile:@"Summa_Geometricheskoy.rtfd.zip"]; } } But on the device it takes some time for the UIWebView to load the content. Is there any way to optimize the loading time?

    Read the article

  • UIWebview: Dynamically adding html content

    - by user739711
    I am making an app in which I get text from my server and display it in UIWebview. After some time more text is added and client(iphone) is notified about the additional-text. Now I want to inject this text into my UIWebview. Anybody know how to do it? One method is to update some text file and reload the content. But I dont want to reload the page. Another way can be to use javascript to check updates in a local file (which seems better). Is there any known better solution?

    Read the article

  • keyboard in UIWebView shows and then hides itself on input focus

    - by Jake
    I have a page that's loading into a UIWebView (which takes 100% of the screen) on an iPad. When I touch a text field, the page positions the text field to the right place and the keyboard starts to come up, but then it turns around and goes back down and blur is called on the input field. When I try this same page in mobile Safari, the keyboard is able to deploy successfully. I can't figure out what the rules are for the keyboard to show successfully and stay up = and why this is different for uiwebview than safari. All my research on the subject has yielded no answers.

    Read the article

  • Alternatives to UIWebView for rich content?

    - by ojreadmore
    In my app, I am displaying 4 "tabs", each are local content through a UIWebView. I create HTML markup from my simple data. This is slow to load and I'm trying to speed it up. I'm using UIWebView to accomplish these: 1. hyperlinks 2. some styling - font colors 3. HTML tables Writing my own class to handle this is okay for (1.) hyperlinks - I can use a touch event to call a method. And (2.) styling - I can use UILables to do basic formatting, no biggie here. BUT what I really love about the UIWebViews is the (3.) HTML tables! I find it troublesome to line up the UILabels in a way that mimics HTML Tables, for instance, one cell's height in a row changes the height of all cells. I'm looking for another perspective or knowledge of an alternative.

    Read the article

  • iphone uiwebview / form

    - by user290031
    Hey All, Okay, so I have an iphone app that presents the user with a UIWebview of an html page with a form I created. The form has standard stuff like a message box and dropdown boxes. Once the user fills out the form and clicks submit, it saves the information as nsstrings in my program. Okay, no problem there. That all works fine. However, I also wanna be able to edit this form as well. Once I save all this information the user selected in the form (as strings), is there a way to put it back into an html form using an uiwebview so a user of the app can edit the info later on?? I apologize in advance if I didn't give enough info.

    Read the article

  • UIWebview isn't displaying content I want it to display

    - by Knodel
    In my app I have a UIWebView which loads different rtf files. I use this function to load these files: - (void)loadFile:(NSString*)file { NSString* resourcePath = [[NSBundle mainBundle] resourcePath]; NSString* sourceFilePath = [resourcePath stringByAppendingPathComponent:file]; NSURL* url = [NSURL fileURLWithPath:sourceFilePath isDirectory:NO]; NSURLRequest* request = [NSURLRequest requestWithURL:url]; [webview loadRequest:request]; } The UIWebView displays nothing. When I enter the debugger, the file string value is which I need, but resourcePath and sourceFilePath values are "nil". What am I doing wrong? Thanks in advance!

    Read the article

  • UIWebView in full screen hides status bar

    - by iPhone
    I am opening video in UIWebView with following code. - (BOOL)webView:(UIWebView *)webView shouldStartLoadWithRequest:(NSURLRequest *)request navigationType:(UIWebViewNavigationType)navigationType { NSLog(@"Navigatin Type %d %@",navigationType, request); if (navigationType == 0) { self.navigationItem.leftBarButtonItem = backBarBtn; [self showVideoInWebView:[request.URL absoluteString]]; return NO; } return YES; } -(void)showVideoInWebView:(NSString *)urlStr { [mainWebView loadRequest:[NSURLRequest requestWithURL:[NSURL URLWithString:urlStr]]]; } but when my mainWebView opens in full screen it hides my status bar. I don't want to hide status bar then how can I show my status bar?

    Read the article

  • how to load local html file into uiwebview iphone

    - by madcoderz
    I'm trying to load a html file into my UIWebView but it won't work. Here's the stage: I have a folder called html_files in my project. Then I created a webView in interface builder and assigned an outlet to it in the viewController. This is the code I'm using to append the html file: -(void)viewDidLoad { NSString *htmlFile = [[NSBundle mainBundle] pathForResource:@"sample" ofType:@"html" inDirectory:@"html_files"]; NSData *htmlData = [NSData dataWithContentsOfFile:htmlFile]; [webView loadData:htmlData MIMEType:@"text/html" textEncodingName:@"UTF-8" baseURL:[NSURL URLWithString:@""]]; [super viewDidLoad]; } That won't work and the UIWebView is blank. I'd appreciate some help.

    Read the article

  • Rendering a UIWebView in drawRect with loadHTMLString

    - by Nick Weaver
    Hello there, I am having a problem with UIWebView. I'd like to render my own html code in it. When I add a webview as a subview and put in some html code it renders just fine. When it gets down to some optimized drawing of tableview cell with the drawRect method the problem pops up. Drawing UIView descendants works pretty well this way. It's even possible to load a URL with the loadRequest method, setting the delegate, conforming to the UIWebViewDelegate protocol and redrawing the table cell with setNeedsDisplay when webViewDidFinishLoad is called. It does show, but when it comes to loadHTMLString, nothing shows up, only a white rect. Due to performance reasons I have to do the drawing in the drawRect method. Any ideas? Thanks in advance Nick Example snippet code for the html code being loaded by a UIWebView: NSString *html = @"<html><head><title>My fancy webview</title></head><body style='background-color:green;'><p>It somehow seems<h2 style='color:black;'>this does not show up in drawRect</h2>!</p></body></html>"; [webView loadHTMLString:html baseURL:nil]; Snippet for the drawRect method: - (void)drawRect:(CGRect)aRect { CGContextRef context = UIGraphicsGetCurrentContext(); [[webView layer] renderInContext:context]; }

    Read the article

  • Why is my UIWebView not scrollable?

    - by Thomas
    In my most frustrating roadblock to date, I've come across a UIWebView that will NOT scroll! I call it via this IBAction: -(IBAction)session2ButtonPressed:(id)sender { Session2ViewController *session2View = [[Session2ViewController alloc]initWithNibName:@"Session2ViewController" bundle:nil]; self.addictionViewController = session2View; [self.view insertSubview:addictionViewController.view atIndex:[self.view.subviews count]]; [session2View release]; } In the viewDidLoad of Session2ViewController.m, I have - (void)viewDidLoad { [super viewDidLoad]; // TRP - Grab data from plist // TRP - Build file path to the plist NSString *filePath = [[NSBundle mainBundle] pathForResource:@"Addiction" ofType:@"plist"]; // TRP - Create NSDictionary with contents of the plist NSDictionary *addictionDict = [NSDictionary dictionaryWithContentsOfFile:filePath]; // TRP - Create an array with contents of the dictionary NSArray *addictionData = [addictionDict objectForKey:@"Addiction1"]; NSLog(@"addictionData (array): %@", addictionData); // TRP - Create a string with the contents of the array NSString *addictionText = [NSString stringWithFormat:@"<DIV style='font-family:%@;font-size:%d;'>%@</DIV>", @"Helvetica", 18, [addictionData objectAtIndex:1]]; addictionInfo.backgroundColor = [UIColor clearColor]; // TRP - Load the string created and stored into addictionText and display in the UIWebView [addictionInfo loadHTMLString:addictionText baseURL:nil]; // TODO: MAKE THIS WEBVIEW SCROLL!!!!!! } In the nib, I connected my web view to the delegate and to the outlet. When I run my main project, the plist with my HTML code shows up, but does not scroll. I copied and pasted this code into a new project, wired the nib the exact same way, and badda-boom badda-bing. . . it works. I even tried to create a new nib from scratch in this project, and the exact same code would not work. Whiskey Tango Foxtrot Any ideas?? Thanks! Thomas

    Read the article

  • Increase content size of UIWebView using Javascript

    - by Sam
    Hi folks, I have a translucent toolbar over the bottom of my UIWebView. The trouble is, if there is a link at the bottom of the page, I can't press it because the webview will always bounce back down to the bottom. I don't want to shrink the webview and use a solid colour toolbar, and UIWebViews interface doesn't open much up. What I would like to do, ideally, is to actually increase the size of the web page by one toolbar height, so that I can scroll that extra bit and have all the content above the toolbar, but when scrolling down I will be able to see the page content through the toolbar. I could use the stringByEvaluatingJavaScriptFromString: function of UIWebView. I'm very rusty on JavaScript- is it possible for me to do this? Increase the window height or something? I tried: [webView stringByEvaluatingJavaScriptFromString: [NSString stringWithFormat:@"window.resizeBy(0,%d);", TOOLBAR_HEIGHT] ]; but it didn't do anything. Any pointers welcome. Thanks.

    Read the article

  • How to disable UIWebview horizontal scrolling?

    - by akaii
    I've tried disabling it by inserting: into my HTML string, and a dozen variations of the above in the vain hope that I just screwed up the tag syntax... but nothing seems to stop UIWebView from scrolling horizontally. And yet there are apps that manage to do this (like MobileRSS), and presumably, since they haven't gotten rejected, they're not using private APIs.

    Read the article

  • UIWebView links inactive

    - by user292781
    I have a webview that displays properly, however the links are entirely inactive. If I try to select a link the selection magnifying glass appears. I've tried overriding - (BOOL)webView:(UIWebView *)webView shouldStartLoadWithRequest:(NSURLRequest *)request navigationType:(UIWebViewNavigationType)navigationType but the method will not execute. The class extends UIViewController <UIWebViewDelegate>, and my view is located in a tabbar, but I'm fairly certain everything's connected properly. Any suggestions?

    Read the article

  • Playing videos in UIWebView broken in iOS4?

    - by rforte
    I have an app that's worked since version 2.0 of the SDK where I create and add a UIWebView and then load the URL of an .mov to play a movie. Ever since the early version of the 4.0 beta up until the 4.0 GM this has stopped working. When I load a movie now I get the following error: :Plug-in handled load" and the movie never displays. Is this a known issue? Am I doing something wrong in 4.0?

    Read the article

  • UIWebView Page Control

    - by Jack
    Hi, I would like to use a UIWebView to display some files (PDF, PPT, DOC) and would like to have the ability to scroll using external controls (ie a couple of buttons that, when pressed skip back and forward a page) and display the current page in a UITextView. Is this possible? I have no experience with javascript, but a friend of mine has suggested that this might be a useful approach. Is his suggestion valid? JP

    Read the article

  • Frame load interrupted error while loading a word document in UIWebView

    - by Mugunth Kumar
    I want to load a word document using UIWebView. I used the code provided in http://developer.apple.com/iphone/library/qa/qa2008/qa1630.html to load the document. But not all the documents load successfully. Sometimes I get an error Error Domain=WebKitErrorDomain Code=102 UserInfo=0x145bc10 "Frame load interrupted" The error seems to be very sporadic and I get this error only for some documents. However the same document loads correctly in mail.app. What am I missing?

    Read the article

  • prevent UIWebView inputs from displaying UIKeyboard without disabling user interaction

    - by Slee
    I have a UIWebView that loads and external product configuration web service UI that is basically a bunch of dependent Drop Down lists. The problem is the Drop Downs are basically enhanced text input's so when the user taps them to display the options the UIKeyboard keeps popping up and own after they make their selection. it is less than a fluid process. Is there anyway to suppress the html inputs from triggering the UIKeyboard?

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >