Posted by Joseph S. on 09/27/05 23:39
This works on my computer, should work on yours as well:
just type yahoo.com in the third field:
<html>
<head>
<title>Variable action field</title>
</head>
<body>
<form action="varaction.php" method="post" name="login" id="login">
Username:<input name="usrname" type="text"/>
Password:<input name="pass" type="password"/>
Domain: http://www.<input name="domain" type="text"/>
<input name="submit" type="submit" value="Login"/>
</form>
<?php
if (isset($_POST['submit'])){
header("Location: http://www.{$_POST['domain']}");
}
?>
</body>
</html>
[Back to original message]
|