View Full Version : New to Dreamweaver : Question about Forms

06-10-2012, 10:31 PM
Hello DreamWeaver Users

I want to create a form in Dreamweaver that asks for the users Name, age, and weight and also has a submit button. When the user hits the submit button I want the output to be on the same page and May read like this

Helllo <Name>

You are <age> and you weight <weight>

I have spent the klast 3-days playing with javascript but wonder if there is an easier way to do this?

06-11-2012, 01:39 AM
you could use php, give the page a .php extension,set the form action to same page and method as post and echo like so

echo "Hello ". $_POST[' name' ]. "<br>";
echo "You are " . $_POST[' age' ];
echo "and you weigh ".$_POST[' weight' ];
$_POST names must match the names of your form fields

06-15-2012, 12:06 PM
You will need a PHP environment for ed's example to work of course. Check out....