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

  • Home
  • SEARCH
  • 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 6009695
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T02:00:30+00:00 2026-05-23T02:00:30+00:00

i have application in which i have a web server api .this is my

  • 0

i have application in which i have a web server api .this is my api

http://192.168.0.68:91/JourneyMapperAPI?RequestType=[<EntityKey>]&Command=[GET|SET|NEW]&Token=[token]&param...n=value..n

RequestType in the query string expects an entity name requested which could be any of the database tables.

Command, in the query string should specify the operation which needs to be performed on the specified request type which could be GET SET or NEW or any other entity specific command.

For eg. i have a register form which allows the user to register.
RequestType for register form is register so the api request on the submit button click of register form would be

http://192.168.0.68:91/JourneyMapperAPI?RequestType=Register&Command=NEW&firstname=rocky&lastname=singh&Username=rocky14&Password=[password]&Email=[email];

How to post this request to server api using http post method with all these parameters and values in it so that the values will be saved in the sever table named register .Please help me in solving this problem.thanks

  • 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-23T02:00:31+00:00Added an answer on May 23, 2026 at 2:00 am

    You can use the below function for posting data to web-server.

    -(void)callCommentWebService:(NSString *)pstrCommentXML{
    
        NSString *soapMsg = 
        [NSString stringWithFormat:
        @"<?xml version=\"1.0\" encoding=\"utf-8\"?>"
        "<soap:Envelope xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\" xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\">"
        "<soap:Body>"
        "<getImageComment xmlns=\"http://tempuri.org/\">"
        "<Commentsxml>%@</Commentsxml>"
        "</getImageComment>"
        "</soap:Body>"
        "</soap:Envelope>", pstrCommentXML
        ];
    
    
        //Create URL Request
        NSURL *url = [NSURL URLWithString: @"http://www.website.com/website/WebService.asmx?op=getImageComment"];
        NSMutableURLRequest *req = [NSMutableURLRequest requestWithURL:url];
    
        //Populate Headers
        NSString *msgLength = [NSString stringWithFormat:@"%d", [soapMsg length]];
        [req addValue:@"text/xml; charset=utf-8"  forHTTPHeaderField:@"Content-Type"];  
        [req addValue:msgLength forHTTPHeaderField:@"Content-Length"];
        [req setHTTPMethod:@"POST"];
        [req setHTTPBody: [soapMsg dataUsingEncoding:NSUTF8StringEncoding]];
    
        conn = [[NSURLConnection alloc] initWithRequest:req delegate:self];
        if (conn)
        {
            webData = [[NSMutableData data] retain];
        }
    }
    

    Here,
    url = you server web-service path

    pstrCommentXML = you XML file whose format defined for upload

    Then you can use simple delegate methods for getting response from server.

    -(void) connection:(NSURLConnection *) connection didReceiveResponse:(NSURLResponse *) response 
    {
        [webData setLength: 0];
    }
    
    -(void) connection:(NSURLConnection *) connection didReceiveData:(NSData *) data 
    {
        [webData appendData:data];
    }
    
    - (void) connection:(NSURLConnection *) connection didFailWithError:(NSError *) error 
    {
        [webData release];
        [connection release];
    }
    
    -(void) connectionDidFinishLoading:(NSURLConnection *) connection 
    {
    
    }
    

    Hope you got the point.

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

Sidebar

Related Questions

No related questions found

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.