Введение в программирование на PHP5



Example.7.1


form_process.php

<?php

echo "Your First Name is: " . $_POST["FName"] . "<br/>"; echo "Your Last Name is: " . $_POST["LName"] . "<br/>"; echo "Your City is: " . $_POST["City"] . "<br/>"; echo "Your State is: " . $_POST["State"] . "<br/>"; echo "<br/>"; echo "Your Message is: " . $_POST["Message"];

?>

<!DOCTYPE html PUBLIC "-//W3C//DTD/XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml11-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <title>A Web Page</title> </head> <body>

<form action="form_process.php" method="post">

First Name: <input type="text" name="FName"/> Last Name: <input type="text" name="LName"/> City: <input type="text" name="City"/> State: <input type="text" name="State"/>

Message: <textarea name="Message" cols="30" rows="5"></textarea>

<input type="submit" name="submit" value="Submit Data"/>

</form>

</body> </html>

Пример 7.1.

Закрыть окно




Содержание  Назад  Вперед