<html><body> @{ if ( IsPost ) { string companyname = Request["CompanyName"]; string contactname = Request["ContactName"]; You entered: Company Name: @companyname Contact Name: @contactname } else { <form method="post" action=""> Company Name: <input type="text" name="CompanyName" value=""> Contact Name: <input type="text" name="ContactName" value=""> <input type="submit" value="Submit" class="submit"> </form> } } </body></html> |