Ver Mensaje Individual
  #1 (permalink)  
Antiguo 03/12/2008, 17:48
tamacun
 
Fecha de Ingreso: diciembre-2008
Mensajes: 2
Antigüedad: 15 años, 5 meses
Puntos: 0
Problema con script PHP, sintax error

Tengo este problema que no consigo arreglar seguro que por mi falta de experiencia (newbie total). Si por favor alguien puede orientarme:
(Me devuelve esto: Parse error: syntax error, unexpected T_VARIABLE in /home/laredwe/public_html/match.php on line 8)

<?php
include('config.php');

$tbl_name1="contacts";
$tbl_name2="registered_members";
$tbl_name3="temp_members_db";
// Retrieve data from $tbl_name1 where row that match this email
$sql1="SELECT('name','email','password','country') FROM"$tbl_name1"INNER_JOIN"$tbl_name2"ON"$tbl_name 1Email=$tblName2Email";
$result1="mysql_result('name','email','password',' country')";
$result1="mysql_query($sql1)";
if($result1) {

// Count how many row has this email
$count=mysql_num_rows('$result1');
// if found this email in our database, retrieve data from table contacts
if($count==1){

$rows = mysql_fetch_array($result1);
$name = $rows['name'];
$email = $rows['email'];
$password = $rows['password'];
$country = $rows['country'];
}
// Insert data that retrieves from "contacts" into "temp_members_db"
$sql2="INSERT INTO $tbl_name3(name,email,password,country)VALUES('$na me','$email','$password','$country')";
$result2=mysql_query($sql2);
}

// if not found email, display message "Wrong email address"
else {
echo "Wrong email address. ";
}
// if successfully moved data from table"contacts" to table "registered_members" displays message "Your account has been activated" "

echo "Your account has been activated";

$sql3="CREATE TABLE $password_db (id int(4) NOT NULL auto_increment,name varchar(65) NOT NULL,email varchar(65) NOT NULL,
password varchar(65) NOT NULL,country varchar(65) NOT NULL,PRIMARY KEY (id),UNIQUE id (id),(id))";
$result3=mysql_query($sql3);
}
echo "Database created";
if($query){

// ---------------- SEND MAIL FORM ----------------
send e-mail to ...
$to=$email;
Your subject
$subject='Mensaje de Confirmacion';
From
$header="";
Your message
$message=" \r\n";
$message.=" \r\n";
$message.="";
send email
$sentmail = mail($to,$subject,$message,$header);

$From='\r\n' $Reply='\r\n' $Return='\r\n'

// if your email succesfully sent
if($sentmail){
echo 'Your Confirmation link Has Been Sent To Your Email Address.';
}
else {
echo 'Due to a system mal function cannot send information link to your e-mail address.';
}


}

?>