19. PHP Program to convert given amount in Dollars into Rupees.
How does this program work?
- This program will help you to easily convert amount in Dollars into Rupees using PHP.
Here is the code
<html>
<head>
<title>PHP Program To convert the Dollars into Rupees</title>
</head>
<body>
<form method="post">
<table border="0">
<tr>
<td> <input type="text" name="num" value="" placeholder="Enter amount in Dollars"/>
</td>
</tr>
<tr>
<td> <input type="submit" name="submit" value="Submit"/>
> </td>
</tr>
</table>
</form>
<?php
if(isset($_POST['submit']))
{
$a = $_POST['num'];
$amount = $a * 71.16;
echo " Total amount $amount in Rupees from $a Dollars ";
return 0;
}
?>
</body>
</html>