PDA

View Full Version : form action problem


Osterling
04-10-2005, 09:04 PM
i have made a button on a vbpage but when i try to click it the action doesn't work right. here is the code:

<form action="pages.php?page=mylink">

so instead of taking me to pages.php?page=mylink it will just take me to pages.php, anyone know what the problem is?

tnguy3n
04-10-2005, 09:29 PM
you gotta define the action mylink in your pages.php file.
i.e.

<?

// some codes here

if($_REQUEST['page'] == 'mylink')
{

// now do something
echo "hello world?";

}

?>

Marco van Herwaarden
04-10-2005, 09:36 PM
You can not pass parameters to a page like this.

You can however set the page parameter as an hidden input field.