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 8823087
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T06:16:03+00:00 2026-06-14T06:16:03+00:00

I am programming the login/register functionality of my app and have everything in order

  • 0

I am programming the login/register functionality of my app and have everything in order so far.

When a user logins in, my php script returns a 1 if successful, and a 0 if unsuccessful. The same is true when they try to register.

My question in, how do I get my app to recognize what value is returned from the php function and respond accordingly?

- (int) authenticateClient {
NSString *loginWeb = [NSString stringWithFormat:(@"http://localhost/login.php?uname=%@&pass=%@&submit=Log%%20In"), user, pass];
NSURL *login = [NSURL URLWithString:loginWeb];
NSData *loginData = [NSData dataWithContentsOfURL: login];
NSMutableURLRequest *loginRequest = [[NSMutableURLRequest alloc] init];
[loginRequest setURL:login];
[loginRequest setTimeoutInterval:10];
  • 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-06-14T06:16:04+00:00Added an answer on June 14, 2026 at 6:16 am

    It sounds like you want to create an API for your mobile app to access. In the php script you could echo back a json container for the data you want to retrieve, and have your app parse the body as json and perform whatever action necessary.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am new to VBA but have previous experience with PHP programming logic and
i have used the login script which is found here http://www.phpeasystep.com/phptu/6.html the script works
I have a login page where user enters Username(textbox), Password(textbox), and location(dropdownlist) then login.
I'm programming in PHP and having some issues with having both a login bar
Have anyone reading the description of PHP user authentication system at Wikibooks? http://en.wikibooks.org/wiki/PHP_Programming/User_login_systems Is
I'm new to web programming. I've created a simple login form (with php). Now
I'm trying to make log in and register script with php and html. It
I am new to iOS programming - I have written an iOS app for
i am new in JavaFX programming. I have an Application, with a simple login
I am new to C# Programming. I had drag a login control into my

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.