Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6741523
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T11:44:06+00:00 2026-05-26T11:44:06+00:00

I have made a login form in html/javascript to be injected into a UIWebView

  • 0

I have made a login form in html/javascript to be injected into a UIWebView in my iPhone application. This all works really well and the login works. But when I press the login button it goes to the expected page within that view.

I was wondering if I could inject some objective c or by ways of a javascript do a modalView or dismissView to have upon the login have the page go to the application.

In the Application I have just made the UI of the webpage more user friendly.

So to kind of show what I am asking I have pasted some code.

NSString *myHTML = @"<form action="gotowebsite.com" onSubmit='return !validateLogin();'><input some textfield><input password field>";

Now I am imagining that the dismissal code will go into the onSubmit area.

Am I on a possibly good track??

Cheers Jeff

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T11:44:06+00:00Added an answer on May 26, 2026 at 11:44 am

    Implement UIWebViewDelegate in your class and on successful login redirect your page to a url like login://success
    when you redirect your page, UIWebview will start loading request and the call the function written below.

    - (BOOL)webView:(UIWebView*)webView shouldStartLoadWithRequest:(NSURLRequest*)request navigationType:(UIWebViewNavigationType)navigationType {
            //CAPTURE USER LINK-CLICK.
              NSURL *url = [request URL];
              NSString *urlStr =   [url absoluteString];
    
              if([urlStr isEqualToString:@"login://success"]){ //same url which you gave for redirection
                 [self dismissModalViewControllerAnimated:YES]; // or do whatever you want to do on a successful login
              }
    
              return YES;   
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have made a web application that uses master page for Login & Logout
I have made a SVG image, or more like mini application, for viewing graphs
I have made a custom UserControl i Vb.net (windows application). How can I add
I have made a new windows service which works fine using barebone code (just
I have made a class which a form can inherit from and it handles
I have made an application (for my self) for feeds reading, using SyndicationFeed ,
I have a login form in Android and i want when i do it
I have a web page containing a login form which loads via HTTP, but
let's start off with the problem statement: My iOS application has a login form.
I am having trouble getting the Auth component redirect. I have a login form

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.