
20/04/2003, 21:19
|
| | Fecha de Ingreso: abril-2003 Ubicación: Santiago
Mensajes: 212
Antigüedad: 21 años, 10 meses Puntos: 0 | |
disculpenme nuevamente pero no entiendo mucho y no puedo pillar el sigiiente error
Parse error: parse error, unexpected $end in F:\Servidor\Apache2\htdocs\Funciones.php on line 32
Fatal error: Call to undefined function: buscar() in F:\Servidor\Apache2\htdocs\Ingreso.php on line 31
<html>
<title>Ingreso.html</title>
<body>
Porfavor Ingrese los siguientes Datos: <br>
(*): Datos Nesesarios.
<form name="ingresar" method="post" action="Ingreso.php">
Nombre de Usuario:
<input name="nomus" type="text" id="nomus"><br>
Clave: &n bsp; &nbs p;
<input type="text" name="passw"> Reconfirmar: <input type="text" name="repas"><br>
Nombre: & nbsp; &nb sp; <input type="text" name="nombre"> Apellido: <i nput type="text" name="apellido"><br>
E-Mail: &n bsp; &nbs p; <input type="text" name="email"><br>
<input type="submit" value="Enviar" name="enviar">
</form>
<?php
include("Funciones.php");
?>
<?php
if(isset($enviar)) {
if(!isset($nomus))
echo "porfavor ingrese un nombre de usurios";
else {
if(!isset($passw))
echo "porfavor ingrese una Password";
else {
if(!isset($repas))
echo "porfavor ingrese la reconfirmacion de la paswword";
else {
if($passw==$repas) {
if(buscar($nomus)) {
guarda($nomus,$passw,$nombre,$apellido,$email);
echo "se ha registrado satisfactoriamente";
}else
echo "el nombre escogido ya existe";
}else
echo "porfavor que las password coinsidan";
}
}
}
}
?>
</body>
</html>
<html>
<head>
<title>Funciones.php</title>
</head>
<body>
<?php
function buscar($nombre) {
$conect=mysql_connect("localhost","root");
mysql_select_db("cofradiamontaraz",$conect);
$tabla=mysql_query("SELECT Nombre_Usuario From integrantes", $conect);
while($row = mysql_fetch_array($tabla)){
if($row["Nombre_Usuario"]==$nombre) {
return false;
mysql_free_result($tabla);
mysql_close($conect);
}
mysql_free_result($tabla);
mysql_close($conect);
return true;
}
?>
<?php
function guarda($nomus,$pass,$nombre,$apellido,$email) {
$conect=mysql_connect("localhost","root");
mysql_select_db("cofradiamontaraz",$conect);
mysql_query("INSERT INTO integrantes(Nombre_Usuario,Password,Nombre,Apellid o,email) values('$nomus','$pass','$nombre','$apellido','$em ail')",$conect);
return;
}
?>
</body>
</html>
y mi consulta puedo hacer muchas funcionesen un archivo php y mandarlas a llamar o si no como puedo hacer eso
bueno el que peua adydarme con este error porfa lo agradesco mucho |