Simple HTML help

Bob - BLU blu at scrunch.net
Tue Mar 28 15:08:07 EST 2006


On 3/24/2006 6:39 PM, Scott Ehrlich wrote:
> I'd like to put together a simple web page where, when visited, it 
> provides a box to enter a URL.  Once entered, it redirects you to the site.

If you want to pursue the php-based approach, consider this code:


<?php if (isset($_POST['url'])) exit(header("Location: {$_POST['url']}")); ?>
<html>
<body>
<form method="POST" action="<?=$_SERVER['PHP_SELF']?>">
        <input type="text" name="url">
        <input type="submit" value="begone">
</form>
</body>
</html>




More information about the Discuss mailing list