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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T06:10:23+00:00 2026-06-10T06:10:23+00:00

Im a newbie at android coding and I looked around a little to try

  • 0

Im a newbie at android coding and I looked around a little to try to find a solution to my problem. The web-site I want to send the data has a form. I want to collect data from my activity in edittext fields and send it to the Web form and submit the web-form.

After some reading online I am across the below method. Can someone tell me if this is correct? If the webform has a field called “name” (I can access the site source). And the user enters “John Doe”, So the NameValue pair will be “name”,”John Doe” right?

HttpClient httpClient = new DefaultHttpClient();
HttpConnectionParams.setConnectionTimeout(httpClient.getParams(),10000);
HttpConnectionParams.setSoTimeout(httpClient.getParams(),10000);
HttpPost httpPost = new HttpPost(url);  
List<NameValuePair> nameValuePairs = new ArrayList<NameValuePair>();  
nameValuePairs.add(new BasicNameValuePair("name1", "value1"));  
nameValuePairs.add(new BasicNameValuePair("name2", "value2")); 
nameValuePairs.add(new BasicNameValuePair("name3", "value3"));   
    // etc...
    try{
        httpPost.setEntity(new UrlEncodedFormEntity(nameValuePairs)); 
        HttpResponse response = httpClient.execute(httpPost);
        BufferedReader br = new BufferedReader(new                InputStreamReader(response.getEntity().getContent()));

    }
    catch(Exception e)
    {

    }
  • 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-10T06:10:25+00:00Added an answer on June 10, 2026 at 6:10 am

    Yes, you are submitting the data via post.
    Just in case you don’t know this: You should post the data to the “form action” page.

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

Sidebar

Related Questions

I'm a newbie in Android Development and I want to implement Spinner . My
I'm still a newbie in Android and I'm trying to work my way around
Im still a newbie in android, would appreciate your help as I couldnt find
I am a newbie to android app development. I want to customize my android
I am a newbie to Android and Java and want to write a function
i'm newbie for android dev, now i want explore file handling in android, for
I am a total newbie when it comes to both java and android coding.
I'm a newbie in android. Could anyone help me to find out tutorials which
I'm a newbie in Android development. Let me explain my problem. I've have a
I'm newbie to Android development. I'm having problem here and hope someone could help

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.