Coding With Fun
Home Docker Django Node.js Articles Python pip guide FAQ Policy

How Web Services is used


May 23, 2021 Web Services


Table of contents


How Web Services uses


Use our ASP.NET web service example

In the previous section, we created an example of a Web service.

Test the Fahrenheit conversion degree Celsius function here: Fahrenheit converts to Celsius

Test the Degrees Celsius conversion fahrenheit function here: Celsius to Fahrenheit

Using HTTP POST, this test sends an XML response like this:

<?xml version="1.0" encoding="utf-8" ?>
<string xmlns="http://tempuri.org/">38</string>


Use forms to access web services

By using forms and HTTP POST, you can place web services on your site, such as this: Fahrenheit to Celsius:

Fahrenheit to Celsius:
Degrees Celsius to Fahrenheit:


You can place web service on your site

You can use this code to place web services on your site:

<form action='tempconvert.asmx/FahrenheitToCelsius'
method="post" target="_blank">
<table>
<tr>
<td>Fahrenheit to Celsius:</td>
<td>
<input class="frmInput" type="text" size="30" name="Fahrenheit">
</td>
</tr>
<tr>
<td></td>
<td align="right">
<input type="submit" value="Submit" class="button">
</td>
</tr>
</table>
</form>

<form action='tempconvert.asmx/CelsiusToFahrenheit'
method="post" target="_blank">
<table>
<tr>
<td>Celsius to Fahrenheit:</td>
<td>
<input class="frmInput" type="text" size="30" name="Celsius">
</td>
</tr>
<tr>
<td></td>
<td align="right">
<input type="submit" value="Submit" class="button">
</td>
</tr>
</table>
</form>

The address of "tempconvert.asmx" on the server is similar to the following:

http://www.example.com/webservices/tempconvert.asmx