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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T09:25:55+00:00 2026-06-17T09:25:55+00:00

i am having this challenge that have been driving me crazy and don’t know

  • 0

i am having this challenge that have been driving me crazy and don’t know how to fix it. I have developed an android application that will post some data to a remote url using post. here is my method to handle that

public static String fetchStringFromRemotePOST(String url,List<NameValuePair> nameValuePairs){
    HttpClient client = new DefaultHttpClient();
    HttpPost post = new HttpPost(url);
    Log.i("URL",url);
    String line = "";
    String content = "";
    try{
        post.setEntity(new UrlEncodedFormEntity(nameValuePairs));
        HttpResponse response = client.execute(post);

        BufferedReader rd = new BufferedReader(new InputStreamReader(response.getEntity().getContent()));

        while ((line = rd.readLine()) != null) {
          content += line;              
        }
    }catch(Exception e){
        Log.d("String Fetch ERROR",e.toString());
    }
    return content;
}

and to call the method

List<NameValuePair> nameValuePairs = new ArrayList<NameValuePair>(1);
nameValuePairs.add(new BasicNameValuePair("post","okpokor"));      
String url = "http://wwww.host.com/post.php";    
String response = UtilMethod.fetchStringFromRemotePOST(url,nameValuePairs);

And also, i have included the internet permission in the Android manifest file

<uses-permission 
        android:name="android.permission.INTERNET" />
<application
 ...

I have gone through the same problem discussed on other threads previously and none of the suggestions really worked for me, suggestions like re-starting the Eclipse and AVD.

Really need help!

  • 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-17T09:25:55+00:00Added an answer on June 17, 2026 at 9:25 am

    Check your URL you have 4

    wwww

    ,
    change it to :

    http://www.host.com/post.php

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

Sidebar

Related Questions

Having this XML view: <?xml version=1.0 encoding=utf-8?> <LinearLayout android:id=@+id/myScrollLayout android:layout_width=fill_parent android:layout_height=fill_parent android:orientation=vertical xmlns:android=http://schemas.android.com/apk/res/android> <ScrollView
having this two classes I always have a doubt of which is the best
I'm having trouble trying to figure out how to achieve this programming challenge in
I'm having quite a challenge... I have a web page where the user clicks
A bit of background info; this is an application that allows users to created
As we know Android coming with various device which having different Features, Resolution, and
I have been scraping the Internet for some solution to this problem with no
I am having a challenge with a piece of code that takes very long
I'm working on an Android application that will come with lots of data. I'd
Apologies for the essay-like nature of this question. I have been struggling to get

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.