title: how to send get and post request in windows phone 8.1
body: <p>I want to implement get and post request in windows phone 8.1 using c#.</p>
  
  <p>I should be able to read the text in the URL using get request and must post something in return it give your id is set with text I have posted.</p>
  
  <p>This is the code I am using for post request.</p>
  
  <pre><code>private async void Button_Click(object sender, RoutedEventArgs e)
  {
      Windows.Web.Http.HttpClient clientOb = new Windows.Web.Http.HttpClient();
      Uri connectionUrl = new Uri("http://www.xyz.in/hoo/test.php/");
      //text.Text  = pairs;
      Dictionary&lt;string, string&gt; pairs = new Dictionary&lt;string, string&gt;();
      pairs.Add("value1", "Hello");
      pairs.Add("value2", "World!");
      Windows.Web.Http.HttpFormUrlEncodedContent formContent = new Windows.Web.Http.HttpFormUrlEncodedContent(pairs);
      Windows.Web.Http.HttpResponseMessage response = await clientOb.PostAsync(connectionUrl, formContent);
      if (response.IsSuccessStatusCode)
      {
          var dialog = new MessageDialog(response.Content.ToString());
          await dialog.ShowAsync();
      }
  }
  </code></pre>
  
  <p>In the above code it just returns the text on the website.</p>