Показать сообщение отдельно
  #3  
Старый 20.06.2011, 10:50
Аватар для T@nker
T@nker T@nker вне форума
Прохожий
 
Регистрация: 27.05.2010
Адрес: г муравленко(ЯНАО)
Сообщения: 40
Версия Delphi: Delphi 7
Репутация: 10
Вопрос полный код

PHP код:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<
html xmlns="http://www.w3.org/1999/xhtml">
<
head>
<
meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<
title>Untitled Document</title>
</
head>

<
body>


<?
PHP*
$user="юзверь";
$pass="пасс";
$connection*=*pg_connect*("host=127.0.0.1*dbname=utali8*user=$user*password=$pass");
$res=pg_query($connection,"INSERT INTO login_db VALUES (nll, ($_POST['login']),($_POST['password']),  ($_POST['name']))");

?>
<p>&nbsp;</p>
</body>
</html> 
сама HTML-форма
Код HTML:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>UTaLI-регистрация юзверя</title> <style type="text/css"> <!-- body { background-color: #006699; } a:link { color: #FFFFFF; } a:visited { color: #0099ff; } a:hover { color: #00ffff; } a:active { color: #ffffff; body,td,th { color: #FFFFFF; } body,td,th { color: #FFFFFF; } --> </style> </head> <body bgcolor="#006699";> <center> <p>Регистрация нового юзверя</p> <table width="200" border="0" bgcolor="#0099ff"> <form method="POST" action="regsubmit.php"> <tr> <td>Логин</td> <td><input type="text" name="login" size="20">&nbsp;</td> </tr> <tr> <td>Пароль</td> <td><input type="password" name="password" size="20">&nbsp;</td> </tr> <tr> <td>ФИО</td><input type="text" name="name" size="20" /> <td>&nbsp;</td> </tr><tr> <td> <input type="submit" value="Сохранить" name="B1"></td><td><input type="reset" value="Сбросить" name="B2"></td></tr> </form> </table> <p>&nbsp;</p> </center> <center> </center> </body> </html>
__________________
Начинающий программист уверен что в 1 МБ 1000 КБ
законченный программист уверен что в 1 км 1024 м
Ответить с цитированием