Parašė Narysx· 2008 Bir. 17 20:06:40
#1
Kodas:
include LOCALE.LOCALESET."members-profile.php";
include LOCALE.LOCALESET."user_fields.php";
//warns\\
if (file_exists(LOCALE.LOCALESET."warns.php")) {
include LOCALE.LOCALESET."warns.php";
} else {
include LOCALE."English/warns.php";
}
$result2=dbquery("SELECT tw.*, tu.user_id,user_name FROM ".$db_prefix."warnings tw
LEFT JOIN ".$db_prefix."users tu ON tw.give_user=tu.user_id WHERE tw.user_id='$lookup' ORDER BY warning_number ASC");
if (dbrows($result2)) {
$warns=dbrows($result2);
} else {$warns='0'; }
//------\\
if (!isset($group_id)) {
if (!isset($lookup) || !isNum($lookup)) fallback("index.php");
$result = dbquery("SELECT * FROM ".$db_prefix."users WHERE user_id='$lookup'");
if (dbrows($result)) { $data = dbarray($result); } else { redirect("index.php"); }
if (!isset($lookup) || !isNum($lookup)) {
fallback("index.php");
} else {
$result = dbquery("SELECT * FROM ".$db_prefix."users WHERE user_id='$lookup'");
if (dbrows($result)) { $data = dbarray($result); } else { redirect("index.php"); }
}
if (!isset($group_id) && !isset($_GET['view'])) {
if (isset($_POST['rate'])) {
if (isNum($_POST['rating']) && !dbcount("(*)","user_ratings","rate_user = '".$userdata['user_id']."' AND rate_subject = '$lookup'") && iMEMBER) {
$result = dbquery("INSERT INTO ".$db_prefix."user_ratings (rate_user,rate_subject,rate_opt,rate_date,rate_ip) VALUES ('".$userdata['user_id']."','$lookup','".$_POST['rating']."','".time()."','".$_SERVER['REMOTE_ADDR']."');");
if ($result) redirect(FUSION_SELF."?lookup=$lookup");
} else {
fallback("http://www.google.lt/");
}
}
opentable($locale['420']);
echo "<table align='center' cellpadding='0' cellspacing='1' width='400' class='tbl-border'>
<tr>
Erroras:
Parse error: syntax error, unexpected $end in /home/lklrsn/nbarsn.gan.lt/profile.php on line 404
404 eilutė:
?>
Jei išimu iš kodo šią vietą:
if (!isset($lookup) || !isNum($lookup)) {
fallback("index.php");
} else {
$result = dbquery("SELECT * FROM ".$db_prefix."users WHERE user_id='$lookup'");
if (dbrows($result)) { $data = dbarray($result); } else { redirect("index.php"); }
}
if (!isset($group_id) && !isset($_GET['view'])) {
if (isset($_POST['rate'])) {
if (isNum($_POST['rating']) && !dbcount("(*)","user_ratings","rate_user = '".$userdata['user_id']."' AND rate_subject = '$lookup'") && iMEMBER) {
$result = dbquery("INSERT INTO ".$db_prefix."user_ratings (rate_user,rate_subject,rate_opt,rate_date,rate_ip) VALUES ('".$userdata['user_id']."','$lookup','".$_POST['rating']."','".time()."','".$_SERVER['REMOTE_ADDR']."');");
if ($result) redirect(FUSION_SELF."?lookup=$lookup");
} else {
fallback("http://www.google.lt/");
}
}
Tuomet erroro nebemeta. Kas per nesamonės? :?