hmm, you could do this in php but you would be much faster doing it in javascript or vbscript.... to complete this task, to the best of my knowledge, you would need to:
1. generate the form.
2. submit the form
3. redirect the page with the correct url.....
<?php
$var = $_GET["form_value"]...