我知道在创建php时,如果您尝试调用未定义的索引,它将从磁贴中发出通知,但是我不知道如何以我试图创建它的方式进行修复。 它非常基本的代码。 形式:
<form action="procesar.php" method="get">
<p>Su nombre: <input type="text" name="nombre"/></p>
<p>Su e-mail: <input type="text" name="email"/></p>
<p><input type="submit" name="Enviar"/></p>
</form>
这是php:
<html>
<body>
<p>Hola <?php echo $_POST ["nombre"]; ?><br></p>
<p>El teu e-mail es: <?php echo $_POST ["email"]; ?></p>
</body>
</html>
我知道html或头部和身体等形式中有一些遗漏的东西,但是我总是这样:
答案 0 :(得分:0)
您将表单作为 CREATE FUNCTION x3()
returns varchar(max)
as
begin
declare @ilk_isim varchar(50)
declare @soy_isim varchar(50)
declare @birlestir varchar(100)
select @ilk_isim = adi from alici where id = 2
select @soy_isim = adi from ilan_veren where id = 1
select @birlestir = @ilk_isim+' '+@soy_isim
return @birlestir
end
select dbo.x3()
请求而不是get
发送。
为了以post
的形式访问变量,您需要按以下方式将表单的method属性更新为$_POST
。
post
这意味着表单将作为<form action="procesar.php" method="post">
<p>Su nombre: <input type="text" name="nombre"/></p>
<p>Su e-mail: <input type="text" name="email"/></p>
<p><input type="submit" name="Enviar"/></p>
</form>
请求而不是POST
请求发送给您的GET