Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> NukeSentinel™
Author Message
scout
New Member
New Member


Joined: Feb 03, 2009
Posts: 13
Location: in front of my pc

PostPosted: Fri Feb 06, 2009 12:27 pm Reply with quote

I may have missed something on the editing of the core files, not 100% sure though, but I'm guessing that is causing this issue when I click on Your Account or Profile links:

Parse error: syntax error, unexpected T_FUNCTION in /modules/Your_Account/index.php on line 882

Any ideas on how to resolve this would be great! Everything else on the site is working fine.
 
View user's profile Send private message Visit poster's website
evaders99
Former Moderator in Good Standing


Joined: Apr 30, 2004
Posts: 3221

PostPosted: Fri Feb 06, 2009 8:05 pm Reply with quote

Would help if you post the code including and around line 882 of that specified file

_________________
- Only registered users can see links on this board! Get registered or login! -

Need help? Only registered users can see links on this board! Get registered or login! 
View user's profile Send private message Visit poster's website
scout
PostPosted: Sat Feb 07, 2009 7:17 am Reply with quote

<?php

/************************************************************************/
/* PHP-NUKE: Web Portal System */
/* =========================== */
/* */
/* Copyright (c) 2006 by Francisco Burzi */
/* Only registered users can see links on this board! Get registered or login! */
/* */
/* This program is free software. You can redistribute it and/or modify */
/* it under the terms of the GNU General Public License as published by */
/* the Free Software Foundation; either version 2 of the License. */
/************************************************************************/

if (!defined('MODULE_FILE')) {
die ("You can't access this file directly...");
}

require_once("mainfile.php");
$module_name = basename(dirname(__FILE__));
get_lang($module_name);
$userpage = 1;
if(isset($_GET['redirect'])) $redirect = substr($_SERVER['QUERY_STRING'], strpos($_SERVER['QUERY_STRING'], "redirect=") + strlen("redirect="), strlen($_SERVER['QUERY_STRING']));

if(is_user($user)) {
include("modules/$module_name/navbar.php");
}

function userCheck($username, $user_email) {
$username = filter($username, "nohtml", 1);
$user_email = filter($user_email, "nohtml", 1);
global $stop, $user_prefix, $db;
if ((!$user_email) || (empty($user_email)) || (!eregi("^[_\.0-9a-z-]+@([0-9a-z][0-9a-z-]+\.)+[a-z]{2,6}$",$user_email))) $stop = "<center>"._ERRORINVEMAIL."</center><br>";
if (strrpos($user_email,' ') > 0) $stop = "<center>"._ERROREMAILSPACES."</center>";
if ((!$username) || (empty($username)) || (ereg("[^a-zA-Z0-9_-]",$username))) $stop = "<center>"._ERRORINVNICK."</center><br>";
if (strlen($username) > 25) $stop = "<center>"._NICK2LONG."</center>";
if (eregi("^((root)|(adm)|(linux)|(webmaster)|(admin)|(god)|(administrator)|(administrador)|(nobody)|(anonymous)|(anonimo)|(anónimo)|(operator)|(JackFromWales4u2))$",$username)) $stop = "<center>"._NAMERESERVED."</center>";
if (strrpos($username,' ') > 0) $stop = "<center>"._NICKNOSPACES."</center>";
if ($db->sql_numrows($db->sql_query("SELECT username FROM ".$user_prefix."_users WHERE username='$username'")) > 0) $stop = "<center>"._NICKTAKEN."</center><br>";
if ($db->sql_numrows($db->sql_query("SELECT username FROM ".$user_prefix."_users_temp WHERE username='$username'")) > 0) $stop = "<center>"._NICKTAKEN."</center><br>";
if ($db->sql_numrows($db->sql_query("SELECT user_email FROM ".$user_prefix."_users WHERE user_email='$user_email'")) > 0) $stop = "<center>"._EMAILREGISTERED."</center><br>";
if ($db->sql_numrows($db->sql_query("SELECT user_email FROM ".$user_prefix."_users_temp WHERE user_email='$user_email'")) > 0) $stop = "<center>"._EMAILREGISTERED."</center><br>";
return $stop;
}

function confirmNewUser($username, $user_email, $user_password, $user_password2, $random_num, $gfx_check) {
global $stop, $EditedMessage, $sitename, $module_name, $minpass;
include("header.php");
include("config.php");
$username = filter($username, "nohtml");
$user_email = filter($user_email, "nohtml");
$user_viewemail = "0";
userCheck($username, $user_email);
$user_email = validate_mail($user_email);
$user_password = htmlspecialchars(stripslashes($user_password));
$user_password2 = htmlspecialchars(stripslashes($user_password2));
if (!$stop) {
$datekey = date("F j");
$rcode = hexdec(md5($_SERVER['HTTP_USER_AGENT'] . $sitekey . $_POST['random_num'] . $datekey));
$code = substr($rcode, 2, 6);
if (extension_loaded("gd") AND $code != $gfx_check AND ($gfx_chk == 3 OR $gfx_chk == 4 OR $gfx_chk == 6 OR $gfx_chk == 7)) {
title(""._NEWUSERERROR."");
OpenTable();
echo "<center><b>"._SECCODEINCOR."</b><br><br>"
.""._GOBACK."</center>";
CloseTable();
include("footer.php");
die();
}
if (empty($user_password) AND empty($user_password2)) {
$user_password = makepass();
} elseif ($user_password != $user_password2) {
title(""._NEWUSERERROR."");
OpenTable();
echo "<center><b>"._PASSDIFFERENT."</b><br><br>"._GOBACK."</center>";
CloseTable();
include("footer.php");
die();
} elseif ($user_password == $user_password2 AND strlen($user_password) < $minpass) {
title(""._NEWUSERERROR."");
OpenTable();
echo "<center>"._YOUPASSMUSTBE." <b>$minpass</b> "._CHARLONG."<br><br>"._GOBACK."</center>";
CloseTable();
include("footer.php");
die();
}
title("$sitename: "._USERREGLOGIN."");
OpenTable();
echo "<center><b>"._USERFINALSTEP."</b><br><br>$username, "._USERCHECKDATA."</center><br><br>"
."<table align='center' border='0'>"
."<tr><td><b>"._UUSERNAME.":</b> $username<br></td></tr>"
."<tr><td><b>"._EMAIL.":</b> $user_email</td></tr></table><br><br>"
."<center><b>"._NOTE."</b> "._YOUWILLRECEIVE."";
echo "<form action=\"modules.php?name=$module_name\" method=\"post\">"
."<input type=\"hidden\" name=\"random_num\" value=\"$random_num\">"
."<input type=\"hidden\" name=\"gfx_check\" value=\"$gfx_check\">"
."<input type=\"hidden\" name=\"username\" value=\"$username\">"
."<input type=\"hidden\" name=\"user_email\" value=\"$user_email\">"
."<input type=\"hidden\" name=\"user_password\" value=\"$user_password\">"
."<input type=\"hidden\" name=\"op\" value=\"finish\"><br><br>"
."<input type=\"submit\" value=\""._FINISH."\"> &nbsp;&nbsp;"._GOBACK."</form></center>";
CloseTable();
} else {
OpenTable();
echo "<center><font class=\"title\"><b>Registration Error!</b></font><br><br>";
echo "<font class=\"content\">$stop<br>"._GOBACK."</font></center>";
CloseTable();
}
include("footer.php");
}

function finishNewUser($username, $user_email, $user_password, $random_num, $gfx_check) {
global $stop, $EditedMessage, $adminmail, $sitename, $Default_Theme, $user_prefix, $db, $storyhome, $module_name, $nukeurl;
include("header.php");
include("config.php");
userCheck($username, $user_email);
$user_email = validate_mail($user_email);
$user_regdate = date("M d, Y");
$user_password = htmlspecialchars(stripslashes($user_password));
if (!isset($stop)) {
$datekey = date("F j");
$rcode = hexdec(md5($_SERVER['HTTP_USER_AGENT'] . $sitekey . $random_num . $datekey));
$code = substr($rcode, 2, 6);
if (extension_loaded("gd") AND $code != $gfx_check AND ($gfx_chk == 3 OR $gfx_chk == 4 OR $gfx_chk == 6 OR $gfx_chk == 7)) {
Header("Location: modules.php?name=$module_name");
die();
}
mt_srand ((double)microtime()*1000000);
$maxran = 1000000;
$check_num = mt_rand(0, $maxran);
$check_num = md5($check_num);
$time = time();
$finishlink = "$nukeurl/modules.php?name=$module_name&op=activate&username=$username&check_num=$check_num";
$new_password = md5($user_password);
$new_password = htmlspecialchars(stripslashes($new_password));
$username = filter($username, "nohtml", 1);
$user_email = filter($user_email, "nohtml", 1);
$result = $db->sql_query("INSERT INTO ".$user_prefix."_users_temp (user_id, username, user_email, user_password, user_regdate, check_num, time) VALUES (NULL, '$username', '$user_email', '$new_password', '$user_regdate', '$check_num', '$time')");
if(!$result) {
echo ""._ERROR."<br>";
} else {
$message = ""._WELCOMETO." $sitename!\n\n"._YOUUSEDEMAIL." ($user_email) "._TOREGISTER." $sitename.\n\n "._TOFINISHUSER."\n\n $finishlink\n\n "._FOLLOWINGMEM."\n\n"._UNICKNAME." $username\n"._UPASSWORD." $user_password";
$subject = ""._ACTIVATIONSUB."";
$from = "$adminmail";
mail($user_email, $subject, $message, "From: $from\nX-Mailer: PHP/" . phpversion());
title("$sitename: "._USERREGLOGIN."");
OpenTable();
echo "<center><b>"._ACCOUNTCREATED."</b><br><br>";
echo ""._YOUAREREGISTERED.""
."<br><br>"
.""._FINISHUSERCONF."<br><br>"
.""._THANKSUSER." $sitename!</center>";
CloseTable();
}
} else {
echo "$stop";
}
include("footer.php");
}

function activate($username, $check_num) {
global $db, $user_prefix, $module_name, $language, $prefix;
$username = filter($username, "nohtml", 1);
$past = time()-86400;
$db->sql_query("DELETE FROM ".$user_prefix."_users_temp WHERE time < $past");
$sql = "SELECT * FROM ".$user_prefix."_users_temp WHERE username='$username' AND check_num='$check_num'";
$result = $db->sql_query($sql);
if ($db->sql_numrows($result) == 1) {
$row = $db->sql_fetchrow($result);
$user_password = htmlspecialchars(stripslashes($row['user_password']));
if ($check_num == $row['check_num']) {
$db->sql_query("INSERT INTO ".$user_prefix."_users (user_id, username, user_email, user_password, user_avatar, user_avatar_type, user_regdate, user_lang) VALUES (NULL, '".$row['username']."', '".$row['user_email']."', '$user_password', 'gallery/blank.gif', '3', '".$row['user_regdate']."', '$language')");
$result2 = $db->sql_query("SELECT user_id FROM ".$user_prefix."_users WHERE username='".$row['username']."'");
$row2 = $db->sql_fetchrow($result2);
$guserid = intval($row2['user_id']);
$db->sql_query("INSERT INTO ".$prefix."_bbgroups (group_name, group_description, group_single_user, group_moderator) VALUES ('', 'Personal User', '1', '0')");
$group_id = $db->sql_nextid();
$db->sql_query("INSERT INTO ".$prefix."_bbuser_group (user_id, group_id, user_pending) VALUES ('$guserid', '$group_id', '0')");
$db->sql_query("DELETE FROM ".$user_prefix."_users_temp WHERE username='$username' AND check_num='$check_num'");
include("header.php");
title(""._ACTIVATIONYES."");
OpenTable();
echo "<center><b>".$row['username'].":</b> "._ACTMSG."</center>";
CloseTable();
include("footer.php");
die();
} else {
include("header.php");
title(""._ACTIVATIONERROR."");
OpenTable();
echo "<center>"._ACTERROR1."</center>";
CloseTable();
include("footer.php");
die();
}
} else {
include("header.php");
title(""._ACTIVATIONERROR."");
OpenTable();
echo "<center>"._ACTERROR2."</center>";
CloseTable();
include("footer.php");
die();
}

}

function userinfo($username, $bypass=0, $hid=0, $url=0) {
global $articlecomm, $user, $cookie, $sitename, $prefix, $user_prefix, $db, $admin, $broadcast_msg, $my_headlines, $module_name, $subscription_url, $admin_file;
$username = filter($username, "nohtml", 1);
$username = substr("$username", 0,25);
$sql = "SELECT * FROM ".$prefix."_bbconfig";
$result = $db->sql_query($sql);
while ( $row = $db->sql_fetchrow($result) )
{
$board_config[$row['config_name']] = $row['config_value'];
}
$sql2 = "SELECT * FROM ".$user_prefix."_users WHERE username='$username'";
$result2 = $db->sql_query($sql2);
$num = $db->sql_numrows($result2);
if ($num != 1) {
Header("Location: modules.php?name=$module_name");
die();
}
$userinfo = $db->sql_fetchrow($result2);
if(!$bypass) cookiedecode($user);
include("header.php");
OpenTable();
echo "<center>";
if ($username != '') // SecurityReason.com Fix 2005 [sp3x]
if((isset($cookie[1])) AND (strtolower($username) == strtolower($cookie[1])) AND ($userinfo['user_password'] == $cookie[2])) {
echo "<font class=\"option\">".htmlentities($username).", "._WELCOMETO." $sitename!</font><br><br>";
echo "<font class=\"content\">"._THISISYOURPAGE."</font></center><br><br>";
nav(1);
echo "<br><br>";
} else {
echo "<font class=\"title\">"._PERSONALINFO.": ".htmlentities($username)."</font></center><br><br>";
}
else Header("Location: modules.php?name=$module_name");
if ($userinfo['user_website']) {
if (!preg_match('#^http[s]?:\/\/#i', $userinfo['user_website'])) {
$userinfo['user_website'] = "http://" . $userinfo['user_website'];
}
if (!preg_match('#^http[s]?\\:\\/\\/[a-z0-9\-]+\.([a-z0-9\-]+\.)?[a-z]+#i', $userinfo['user_website'])) {
$userinfo['user_website'] = '';
}
}
if ($userinfo['user_avatar_type'] == 1) {
$userinfo['user_avatar'] = $board_config['avatar_path']."/".$userinfo['user_avatar'];
} elseif ($userinfo['user_avatar_type'] == 2) {
$userinfo['user_avatar'] = $userinfo['user_avatar'];
} else {
$userinfo['user_avatar'] = $board_config['avatar_gallery_path']."/".$userinfo['user_avatar'];
}
if(($num == 1) && ($userinfo['user_website'] || $userinfo['femail'] || $userinfo['bio'] || $userinfo['user_avatar'] || $userinfo['user_icq'] || $userinfo['user_aim'] || $userinfo['user_yim'] || $userinfo['user_msnm'] || $userinfo['user_location'] || $userinfo['user_occ'] || $userinfo['user_interests'] || $userinfo['user_sig'])) {
echo "<center><font class=\"content\">";
echo "<img src=\"".$userinfo['user_avatar']."\"><br><br>\n";
if ($userinfo['user_website'] != "http://" AND !empty($userinfo['user_website'])) { echo ""._MYHOMEPAGE." <a href=\"".$userinfo['user_website']."\" target=\"new\">".$userinfo['user_website']."</a><br>\n"; }
if ($userinfo['femail']) { echo ""._MYEMAIL." <a href=\"mailto:".$userinfo['femail']."\">".$userinfo['femail']."</a><br>\n"; }
if ($userinfo['user_icq'] && preg_match('/^[0-9]+$/', $userinfo['user_icq'])) echo ""._ICQ.": ".$userinfo['user_icq']."<br>\n";
if ($userinfo['user_aim']) echo ""._AIM.": ".$userinfo['user_aim']."<br>\n";
if ($userinfo['user_yim']) echo ""._YIM.": ".$userinfo['user_yim']."<br>\n";
if ($userinfo['user_msnm']) echo ""._MSNM.": ".$userinfo['user_msnm']."<br>\n";
if ($userinfo['user_from']) echo ""._LOCATION.": ".$userinfo['user_from']."<br>\n";
if ($userinfo['user_occ']) echo ""._OCCUPATION.": ".$userinfo['user_occ']."<br>\n";
if ($userinfo['user_interests']) echo ""._INTERESTS.": ".$userinfo['user_interests']."<br>\n";
$userinfo['user_sig'] = nl2br($userinfo['user_sig']);
if ($userinfo['user_sig']) echo "<br><b>"._SIGNATURE.":</b><br>".$userinfo['user_sig']."<br>\n";
if ($userinfo['bio']) { echo "<br><b>"._EXTRAINFO.":</b><br>".$userinfo['bio']."<br>\n"; }
$sql2 = "SELECT uname FROM ".$prefix."_session WHERE uname='$username'";
$result2 = $db->sql_query($sql2);
$row2 = $db->sql_fetchrow($result2);
$username_pm = $username;
$username_online = $row2['uname'];
if (empty($username_online)) {
$online = _OFFLINE;
} else {
$online = _ONLINE;
}
echo "<br><br>"._USERSTATUS.": <b>$online</b><br>\n";
if (($userinfo['newsletter'] == 1) AND ($username == $cookie[1]) AND ($userinfo['user_password'] == $cookie[2]) OR (is_admin($admin) AND ($userinfo['newsletter'] == 1))) {
echo "<i>"._SUBSCRIBED."</i><br>";
} elseif ((isset($cookie[1])) AND ($userinfo['newsletter'] == 0) AND ($username == $cookie[1]) AND ($userinfo['user_password'] == $cookie[2]) OR (is_admin($admin) AND ($userinfo['newsletter'] == 0))) {
echo "<i>"._NOTSUBSCRIBED."</i><br>";
}
if (is_user($user) AND $cookie[1] == "$username" OR is_admin($admin)) {
$numpoints = $db->sql_fetchrow($db->sql_query("SELECT points FROM ".$user_prefix."_users WHERE user_id = '".intval($cookie[0])."'"));
$n_points = intval($numpoints['points']);
echo ""._YOUHAVEPOINTS." <b>$n_points</b><br>";
if (paid()) {
$row = $db->sql_fetchrow($db->sql_query("SELECT * FROM ".$prefix."_subscriptions WHERE userid='".intval($cookie[0])."'"));
if (!empty($subscription_url)) {
$content = "<br><center>"._YOUARE." <a href='$subscription_url'>"._SUBSCRIBER."</a> "._OF." $sitename<br>";
} else {
$content = "<br><center>"._YOUARE." "._SUBSCRIBER." "._OF." $sitename<br>";
}
$diff = $row['subscription_expire']-time();
$yearDiff = floor($diff/60/60/24/365);
$diff -= $yearDiff*60*60*24*365;
if ($yearDiff < 1) {
$diff = $row['subscription_expire']-time();
}
$daysDiff = floor($diff/60/60/24);
$diff -= $daysDiff*60*60*24;
$hrsDiff = floor($diff/60/60);
$diff -= $hrsDiff*60*60;
$minsDiff = floor($diff/60);
$diff -= $minsDiff*60;
$secsDiff = $diff;
if ($yearDiff < 1) {
$rest = "$daysDiff "._SBDAYS.", $hrsDiff "._SBHOURS.", $minsDiff "._SBMINUTES.", $secsDiff "._SBSECONDS."";
} elseif ($yearDiff == 1) {
$rest = "$yearDiff "._SBYEAR.", $daysDiff "._SBDAYS.", $hrsDiff "._SBHOURS.", $minsDiff "._SBMINUTES.", $secsDiff "._SBSECONDS."";
} elseif ($yearDiff > 1) {
$rest = "$yearDiff "._SBYEARS.", $daysDiff "._SBDAYS.", $hrsDiff "._SBHOURS.", $minsDiff "._SBMINUTES.", $secsDiff "._SBSECONDS."";
}
$content .= "<b>"._SUBEXPIREIN."<br><font color='#FF0000'>$rest</font></b></center>";
} else {
if (!empty($subscription_url)) {
$content .= "<br><center>"._NOTSUB." $sitename. "._SUBFROM." <a href='$subscription_url'>"._HERE."</a> "._NOW."";
} else {
$content .= "<br><center>"._NOTSUB." $sitename.";
}
}
echo "$content<br><br>";
if (is_admin($admin)) {
$subnum = $db->sql_numrows($db->sql_query("SELECT * FROM ".$prefix."_subscriptions WHERE userid='".intval($userinfo['user_id'])."'"));
if ($subnum != 0) {
echo "<center><b>"._ADMSUB."</b></center><br>";
$row = $db->sql_fetchrow($db->sql_query("SELECT * FROM ".$prefix."_subscriptions WHERE userid='".intval($userinfo['user_id'])."'"));
$diff = $row['subscription_expire']-time();
$yearDiff = floor($diff/60/60/24/365);
$diff -= $yearDiff*60*60*24*365;
if ($yearDiff < 1) {
$diff = $row['subscription_expire']-time();
}
$daysDiff = floor($diff/60/60/24);
$diff -= $daysDiff*60*60*24;
$hrsDiff = floor($diff/60/60);
$diff -= $hrsDiff*60*60;
$minsDiff = floor($diff/60);
$diff -= $minsDiff*60;
$secsDiff = $diff;
if ($yearDiff < 1) {
$rest = "$daysDiff "._SBDAYS.", $hrsDiff "._SBHOURS.", $minsDiff "._SBMINUTES.", $secsDiff "._SBSECONDS."";
} elseif ($yearDiff == 1) {
$rest = "$yearDiff "._SBYEAR.", $daysDiff "._SBDAYS.", $hrsDiff "._SBHOURS.", $minsDiff "._SBMINUTES.", $secsDiff "._SBSECONDS."";
} elseif ($yearDiff > 1) {
$rest = "$yearDiff "._SBYEARS.", $daysDiff "._SBDAYS.", $hrsDiff "._SBHOURS.", $minsDiff "._SBMINUTES.", $secsDiff "._SBSECONDS."";
}
$content = "<b>"._ADMSUBEXPIREIN."<br><font color='#FF0000'>$rest</font></b><br><br>";
echo "$content";
} else {
echo "<center><b>"._ADMNOTSUB."</b><br><br>";
}
}
}
if (is_active("Journal") AND $cookie[1] != $username) {
$sql3 = "SELECT jid FROM ".$prefix."_journal WHERE aid='$username' AND status='yes' ORDER BY pdate,jid DESC LIMIT 0,1";
$result3 = $db->sql_query($sql3);
$row3 = $db->sql_fetchrow($result3);
$jid = intval($row3['jid']);
if (!empty($jid) AND isset($jid)) {
echo "[ <a href=\"journal.html?amp;file=search&amp;bywhat=aid&amp;forwhat=$username\">"._READMYJOURNAL."</a> ]<br>";
}
}
if (is_admin($admin)) {
echo "<br>";
OpenTable2();
if ($userinfo['last_ip'] != 0) {
echo "<center><font class=\"title\">"._ADMINFUNCTIONS."</font><br><br>"._LASTIP." <b>".$userinfo['last_ip']."</b><br><br>";
echo "[ <a href='".$admin_file.".php?op=ABBlockedIPAdd&tip=".$userinfo['last_ip']."'>"._BANTHIS."</a> | <a href=\"".$admin_file.".php?op=modifyUser&chng_uid=".$userinfo['username']."\">"._EDITUSER."</a> ]</center>";

} else {
echo "<center>[ <a href=\"".$admin_file.".php?op=modifyUser&chng_uid=".$userinfo['username']."\">"._EDITUSER."</a> ]</center>";
}
if ($userinfo['karma'] == 0) {
$karma = _KARMAGOOD;
$karma_help = _KARMAGOODHLP;
$change_karma = "<a href=\"modules.php?name=$module_name&op=change_karma&user_id=".$userinfo['user_id']."&karma=1\"><img src=\"images/karma/1.gif\" border=\"0\" alt=\""._KARMALOW."\" title=\""._KARMALOW."\" hspace=\"5\"></a>";
$change_karma .= "<a href=\"modules.php?name=$module_name&op=change_karma&user_id=".$userinfo['user_id']."&karma=2\"><img src=\"images/karma/2.gif\" border=\"0\" alt=\""._KARMABAD."\" title=\""._KARMABAD."\" hspace=\"5\"></a>";
$change_karma .= "<a href=\"modules.php?name=$module_name&op=change_karma&user_id=".$userinfo['user_id']."&karma=3\"><img src=\"images/karma/3.gif\" border=\"0\" alt=\""._KARMADEVIL."\" title=\""._KARMADEVIL."\" hspace=\"5\"></a>";
} elseif ($userinfo['karma'] == 1) {
$karma = _KARMALOW;
$karma_help = _KARMALOWHLP;
$change_karma = "<a href=\"modules.php?name=$module_name&op=change_karma&user_id=".$userinfo['user_id']."&karma=0\"><img src=\"images/karma/0.gif\" border=\"0\" alt=\""._KARMAGOOD."\" title=\""._KARMAGOOD."\" hspace=\"5\"></a>";
$change_karma .= "<a href=\"modules.php?name=$module_name&op=change_karma&user_id=".$userinfo['user_id']."&karma=2\"><img src=\"images/karma/2.gif\" border=\"0\" alt=\""._KARMABAD."\" title=\""._KARMABAD."\" hspace=\"5\"></a>";
$change_karma .= "<a href=\"modules.php?name=$module_name&op=change_karma&user_id=".$userinfo['user_id']."&karma=3\"><img src=\"images/karma/3.gif\" border=\"0\" alt=\""._KARMADEVIL."\" title=\""._KARMADEVIL."\" hspace=\"5\"></a>";
} elseif ($userinfo['karma'] == 2) {
$karma = _KARMABAD;
$karma_help = _KARMABADHLP;
$change_karma = "<a href=\"modules.php?name=$module_name&op=change_karma&user_id=".$userinfo['user_id']."&karma=0\"><img src=\"images/karma/0.gif\" border=\"0\" alt=\""._KARMAGOOD."\" title=\""._KARMAGOOD."\" hspace=\"5\"></a>";
$change_karma .= "<a href=\"modules.php?name=$module_name&op=change_karma&user_id=".$userinfo['user_id']."&karma=1\"><img src=\"images/karma/1.gif\" border=\"0\" alt=\""._KARMALOW."\" title=\""._KARMALOW."\" hspace=\"5\"></a>";
$change_karma .= "<a href=\"modules.php?name=$module_name&op=change_karma&user_id=".$userinfo['user_id']."&karma=3\"><img src=\"images/karma/3.gif\" border=\"0\" alt=\""._KARMADEVIL."\" title=\""._KARMADEVIL."\" hspace=\"5\"></a>";
} elseif ($userinfo['karma'] == 3) {
$karma = _KARMADEVIL;
$karma_help = _KARMADEVILHLP;
$change_karma = "<a href=\"modules.php?name=$module_name&op=change_karma&user_id=".$userinfo['user_id']."&karma=0\"><img src=\"images/karma/0.gif\" border=\"0\" alt=\""._KARMAGOOD."\" title=\""._KARMAGOOD."\" hspace=\"5\"></a>";
$change_karma .= "<a href=\"modules.php?name=$module_name&op=change_karma&user_id=".$userinfo['user_id']."&karma=1\"><img src=\"images/karma/1.gif\" border=\"0\" alt=\""._KARMALOW."\" title=\""._KARMALOW."\" hspace=\"5\"></a>";
$change_karma .= "<a href=\"modules.php?name=$module_name&op=change_karma&user_id=".$userinfo['user_id']."&karma=2\"><img src=\"images/karma/2.gif\" border=\"0\" alt=\""._KARMABAD."\" title=\""._KARMABAD."\" hspace=\"5\"></a>";
}
echo "<center><br><br>"._USERKARMA." <img src=\"images/karma/".$userinfo['karma'].".gif\" border=\"0\" alt=\"$karma\" title=\"$karma\"> ($karma)<br>($karma_help)</center><br><br>";
OpenTable2();
echo "<center><b>"._CHANGEKARMA." <i>".$userinfo['username']."</i></b><br><br>";
echo "$change_karma</center>";
CloseTable2();
echo "<br>";
echo "<table border=\"0\" width=\"80%\" cellpadding=\"3\" cellspacing=\"3\" align=\"center\">";
echo "<tr><td valign=\"middle\"><img src=\"images/karma/0.gif\" border=\"0\" alt=\""._KARMAGOOD."\" title=\""._KARMAGOOD."\"></td><td>"._KARMAGOODREF."</td></tr>";
echo "<tr><td valign=\"middle\"><img src=\"images/karma/1.gif\" border=\"0\" alt=\""._KARMALOW."\" title=\""._KARMALOW."\"></td><td>"._KARMALOWREF."</td></tr>";
echo "<tr><td valign=\"middle\"><img src=\"images/karma/2.gif\" border=\"0\" alt=\""._KARMABAD."\" title=\""._KARMABAD."\"></td><td>"._KARMABADREF."</td></tr>";
echo "<tr><td valign=\"middle\"><img src=\"images/karma/3.gif\" border=\"0\" alt=\""._KARMADEVIL."\" title=\""._KARMADEVIL."\"></td><td>"._KARMADEVILREF."</td></tr></table>";
CloseTable2();
}
if (((is_user($user) AND $cookie[1] != $username) OR is_admin($admin)) AND is_active("Private_Messages")) { echo "<br>[ <a href=\"modules.php?name=Private_Messages&amp;mode=post&amp;u=".intval($userinfo['user_id'])."\">"._USENDPRIVATEMSG." $username_pm</a> ]<br>\n"; }
echo "</center></font>";
} else {
echo "<center>"._NOINFOFOR." ".htmlentities($username)."</center>";
}
CloseTable();
if ((isset($cookie[1])) AND $my_headlines == 1 AND ($username == $cookie[1]) AND ($userinfo['user_password'] == $cookie[2])) {
echo "<br>";
OpenTable();
echo "<center><b>"._MYHEADLINES."</b><br><br>"
.""._SELECTASITE."<br><br>"
."<form action=\"modules.php?name=$module_name\" method=\"post\">"
."<input type=\"hidden\" name=\"op\" value=\"userinfo\">"
."<input type=\"hidden\" name=\"username\" value=\"$username\">"
."<input type=\"hidden\" name=\"bypass\" value=\"$bypass\">"
."<input type=\"hidden\" name=\"url\" value=\"0\">"
."<select name=\"hid\" onChange='submit()'>\n"
."<option value=\"0\">"._SELECTASITE2."</option>";
$sql4 = "SELECT hid, sitename FROM ".$prefix."_headlines ORDER BY sitename";
$headl = $db->sql_query($sql4);
while($row4 = $db->sql_fetchrow($headl)) {
$nhid = intval($row4['hid']);
$hsitename = filter($row4['sitename'], "nohtml");
if ($hid == $nhid ) {
$sel = "selected";
} else {
$sel = "";
}
echo "<option value=\"$nhid\" $sel>$hsitename</option>\n";
}
echo "</select></form>"
.""._ORTYPEURL."<br><br>"
."<form action=\"modules.php?name=$module_name\" method=\"post\">"
."<input type=\"hidden\" name=\"op\" value=\"userinfo\">"
."<input type=\"hidden\" name=\"username\" value=\"$username\">"
."<input type=\"hidden\" name=\"bypass\" value=\"$bypass\">"
."<input type=\"hidden\" name=\"hid\" value=\"0\">"
."<input type=\"text\" name=\"url\" size=\"40\" maxlength=\"200\" value=\"http://\">&nbsp;&nbsp;"
."<input type=\"submit\" value=\""._GO."\"></form>"
."</center><br>";
if ($hid != 0 OR ($hid == 0 AND $url != "0" AND $url != "http://") AND !empty($url)) {
if ($hid != 0) {
$sql5 = "SELECT sitename, headlinesurl FROM ".$prefix."_headlines WHERE hid='$hid'";
$result5 = $db->sql_query($sql5);
$row5 = $db->sql_fetchrow($result5);
$nsitename = filter($row5[sitename], "nohtml");
$url = filter($row5[headlinesurl], "nohtml");
$title = filter($nsitename, "nohtml");
$siteurl = eregi_replace("http://", "", $url);
$siteurl = explode("/", $siteurl);
} else {
if (!ereg("http://", $url)) {
$url = "http://$url";
}
$siteurl = eregi_replace("http://", "", $url);
$siteurl = explode("/", $siteurl);
$title = "http://$siteurl[0]";
}
$rdf = parse_url($url);
$fp = fsockopen($rdf['host'], 80, $errno, $errstr, 15);
if (!$fp) {
$content = "<center><font class=\"content\">"._RSSPROBLEM."</font></center>";
}
if ($fp) {
fputs($fp, "GET " . $rdf['path'] . "?" . $rdf['query'] . " HTTP/1.0\r\n");
fputs($fp, "HOST: " . $rdf['host'] . "\r\n\r\n");
$string = "";
while(!feof($fp)) {
$pagetext = fgets($fp,300);
$string .= chop($pagetext);
}
fputs($fp,"Connection: close\r\n\r\n");
fclose($fp);
$items = explode("</item>",$string);
$content = "<font class=\"content\">";
for ($i=0;$i<10;$i++) {
$link = ereg_replace(".*<link>","",$items[$i]);
$link = ereg_replace("</link>.*","",$link);
$link = stripslashes(check_html($link, "nohtml"));
$title2 = ereg_replace(".*<title>","",$items[$i]);
$title2 = ereg_replace("</title>.*","",$title2);
$title2 = stripslashes(check_html($title2, "nohtml"));
if (empty($items[$i]) AND $cont != 1) {
$content = "<center>"._RSSPROBLEM."</center>";
} else {
if (strcmp($link,$title2) AND !empty($items[$i])) {
$cont = 1;
$content .= "<img src=\"images/arrow.gif\" border=\"0\" hspace=\"5\"><a href=\"$link\" target=\"new\">$title2</a><br>\n";
}
}
}
}
if (!empty($content)) {
OpenTable2();
echo "<center><b>"._HEADLINESFROM." <a href=\"http://$siteurl[0]\" target=\"new\">$title</a></b></center><br>";
echo "$content";
CloseTable2();
} elseif (($cont == 0) OR (empty($content))) {
OpenTable2();
echo "<center>"._RSSPROBLEM."</center><br>";
CloseTable2();
}
echo "<br>";
}
CloseTable();
}
if ((isset($cookie[1])) AND $broadcast_msg == 1 AND ($username == $cookie[1]) AND ($userinfo['user_password'] == $cookie[2])) {
echo "<br>";
OpenTable();
echo "<center><b>"._BROADCAST."</b><br><br>"._BROADCASTTEXT."<br><br>"
."<form action=\"modules.php?name=$module_name\" method=\"post\">"
."<input type=\"hidden\" name=\"who\" value=\"$username\">"
."<input type=\"hidden\" name=\"op\" value=\"broadcast\">"
."<input type=\"text\" size=\"60\" maxlength=\"255\" name=\"the_message\">&nbsp;&nbsp;<input type=\"submit\" value=\""._SEND."\">"
."</form></center>";
CloseTable();
}
if ((isset($cookie[1])) AND is_active("Private_Messages") AND ($username == $cookie[1]) AND ($userinfo['user_password'] == $cookie[2])) {
echo "<br>";
OpenTable();
echo "<center><b>"._PRIVATEMESSAGES."</b><br><br>";
$numrow = $db->sql_numrows($db->sql_query("SELECT * FROM ".$prefix."_bbprivmsgs WHERE privmsgs_to_userid='".intval($userinfo['user_id'])."' AND (privmsgs_type='1' OR privmsgs_type='5' OR privmsgs_type='0')"));
if (is_active("Members_List")) {
$mem_list = "<a href=\"members.html\">"._BROWSEUSERS."</a>";
} else {
$mem_list = "";
}
if (is_active("Search")) {
$mod_search = "<a href=\"modules.php?name=Search&amp;type=users\">"._SEARCHUSERS."</a>";
} else {
$mod_search = "";
}
if (!empty($mem_list) AND !empty($mod_search)) { $a = " | "; } else { $a = ""; }
if (!empty($mem_list) OR !empty($mod_search)) {
$links = "[ $mem_list $a $mod_search ]";
} elseif (empty($mem_list) AND empty($mod_search)) {
$links = "";
}

echo ""._YOUHAVE." <a href=\"messages.html\"><b>$numrow</b></a> "._PRIVATEMSG."<br><br>"
."<form action=\"messages.html\" method=\"post\">"
.""._USENDPRIVATEMSG.": <input type=\"text\" name=\"pm_uname\" size=\"20\">&nbsp;&nbsp;$links"
."<input type=\"hidden\" name=\"send\" value=\"1\">"
."</form></center>";
CloseTable();
}
if ($articlecomm == 1) {
echo "<br>";
OpenTable();
echo "<b>"._LAST10COMMENTS." ".$userinfo['username'].":</b><br>";
$sql6 = "SELECT tid, sid, subject FROM ".$prefix."_comments WHERE name='".$userinfo['username']."' ORDER BY tid DESC LIMIT 0,10";
$result6 = $db->sql_query($sql6);
while($row6 = $db->sql_fetchrow($result6)) {
$tid = intval($row6['tid']);
$sid = intval($row6['sid']);
$subject = filter($row6['subject'], "nohtml");
echo "<li><a href=\"modules.php?name=News&file=article&thold=-1&mode=flat&order=0&sid=$sid#$tid\">$subject</a><br>";
}
CloseTable();
}
echo "<br>";
OpenTable();
echo "<b>"._LAST10SUBMISSIONS." ".$userinfo['username'].":</b><br>";
$sql7 = "SELECT sid, title FROM ".$prefix."_stories WHERE informant='".$userinfo['username']."' ORDER BY sid DESC LIMIT 0,10";
$result7 = $db->sql_query($sql7);
while($row7 = $db->sql_fetchrow($result7)) {
$sid = intval($row7['sid']);
$title = filter($row7['title'], "nohtml");
echo "<li><a href=\"article.html$sid\">$title</a><br>";
}
CloseTable();
include("footer.php");
}

function main($user) {
global $stop, $module_name, $redirect, $mode, $t, $f, $gfx_chk;
if(!is_user($user)) {
include("header.php");
if ($stop) {
OpenTable();
echo "<center><font class=\"title\"><b>"._LOGININCOR."</b></font></center>\n";
CloseTable();
echo "<br>\n";
} else {
OpenTable();
echo "<center><font class=\"title\"><b>"._USERREGLOGIN."</b></font></center>\n";
CloseTable();
echo "<br>\n";
}
if (!is_user($user)) {
OpenTable();
mt_srand ((double)microtime()*1000000);
$maxran = 1000000;
$random_num = mt_rand(0, $maxran);
echo "<form action=\"modules.php?name=$module_name\" method=\"post\">\n"
."<b>"._USERLOGIN."</b><br><br>\n"
."<table border=\"0\"><tr><td>\n"
.""._NICKNAME.":</td><td><input type=\"text\" name=\"username\" size=\"15\" maxlength=\"25\"></td></tr>\n"
."<tr><td>"._PASSWORD.":</td><td><input type=\"password\" name=\"user_password\" size=\"15\" maxlength=\"20\"></td></tr>\n";
if (extension_loaded("gd") AND ($gfx_chk == 2 OR $gfx_chk == 4 OR $gfx_chk == 5 OR $gfx_chk == 7)) {
echo "<tr><td colspan='2'>"._SECURITYCODE.": <img src='?gfx=gfx&random_num=$random_num' border='1' alt='"._SECURITYCODE."' title='"._SECURITYCODE."'></td></tr>\n"
."<tr><td colspan='2'>"._TYPESECCODE.": <input type=\"text\" NAME=\"gfx_check\" SIZE=\"7\" MAXLENGTH=\"6\"></td></tr>\n"
."<input type=\"hidden\" name=\"random_num\" value=\"$random_num\">\n";
}
echo "</table><input type=\"hidden\" name=\"redirect\" value=\"$redirect\">\n"
."<input type=\"hidden\" name=\"mode\" value=$mode>\n"
."<input type=\"hidden\" name=\"f\" value=$f>\n"
."<input type=\"hidden\" name=\"t\" value=$t>\n"
."<input type=\"hidden\" name=\"op\" value=\"login\">\n"
."<input type=\"submit\" value=\""._LOGIN."\"></form><br>\n\n"
."<center><font class=\"content\">[ <a href=\"modules.php?name=$module_name&amp;op=pass_lost\">"._PASSWORDLOST."</a> | <a href=\"modules.php?name=$module_name&amp;op=new_user\">"._REGNEWUSER."</a> ]</font></center>\n";
CloseTable();
}
include("footer.php");
} elseif (is_user($user)) {
global $cookie;
cookiedecode($user);
userinfo($cookie[1]);
}
}

function new_user() {
global $my_headlines, $module_name, $db, $gfx_chk, $user;
if (!is_user($user)) {
mt_srand ((double)microtime()*1000000);
$maxran = 1000000;
$random_num = mt_rand(0, $maxran);
include("header.php");
OpenTable();
echo "<center><font class=\"title\"><b>"._USERREGLOGIN."</b></font></center>\n";
CloseTable();
echo "<br>\n";
OpenTable();
echo "<form action=\"modules.php?name=$module_name\" method=\"post\">\n"
."<b>"._REGNEWUSER."</b> ("._ALLREQUIRED.")<br><br>\n"
."<table cellpadding=\"0\" cellspacing=\"10\" border=\"0\">\n"
."<tr><td>"._NICKNAME.":</td><td><input type=\"text\" name=\"username\" size=\"30\" maxlength=\"25\"></td></tr>\n"
."<tr><td>"._EMAIL.":</td><td><input type=\"text\" name=\"user_email\" size=\"30\" maxlength=\"255\"></td></tr>\n"
."<tr><td>"._PASSWORD.":</td><td><input type=\"password\" name=\"user_password\" size=\"11\" maxlength=\"40\"></td></tr>\n"
."<tr><td>"._RETYPEPASSWORD.":</td><td><input type=\"password\" name=\"user_password2\" size=\"11\" maxlength=\"40\"><br><font class=\"tiny\">("._BLANKFORAUTO.")</font></td></tr>\n";
if (extension_loaded("gd") AND ($gfx_chk == 3 OR $gfx_chk == 4 OR $gfx_chk == 6 OR $gfx_chk == 7)) {
echo "<tr><td>"._SECURITYCODE.":</td><td><img src='?gfx=gfx&random_num=$random_num' border='1' alt='"._SECURITYCODE."' title='"._SECURITYCODE."'></td></tr>\n"
."<tr><td>"._TYPESECCODE.":</td><td><input type=\"text\" NAME=\"gfx_check\" SIZE=\"7\" MAXLENGTH=\"6\"></td></tr>\n"
."<input type=\"hidden\" name=\"random_num\" value=\"$random_num\">\n";
}
echo "<tr><td colspan='2'>\n"
."<input type=\"hidden\" name=\"op\" value=\"new user\">\n"
."<input type=\"submit\" value=\""._NEWUSER."\">\n"
."</td></tr></table>\n"
."</form>\n"
."<br>\n"
.""._YOUWILLRECEIVE."<br><br>\n"
.""._COOKIEWARNING."<br>\n"
.""._ASREGUSER."<br>\n"
."<ul>\n"
."<li>"._ASREG1."\n"
."<li>"._ASREG2."\n"
."<li>"._ASREG3."\n"
."<li>"._ASREG4."\n"
."<li>"._ASREG5."\n";
$handle=opendir('themes');
$thmcount = 0;
while ($file = readdir($handle)) {
if ((!ereg("[.]",$file) AND file_exists("themes/$file/theme.php"))) {
$thmcount++;
}
}
closedir($handle);
if ($thmcount > 1) {
echo "<li>"._ASREG6."\n";
}
$sql = "SELECT custom_title FROM ".$prefix."_modules WHERE active='1' AND view='1' AND inmenu='1'";
$result = $db->sql_query($sql);
while ($row = $db->sql_fetchrow($result)) {
$custom_title = filter($row[custom_title], "nohtml");
if (!empty($custom_title)) {
echo "<li>"._ACCESSTO." $custom_title\n";
}
}
$sql = "SELECT title FROM ".$prefix."_blocks WHERE active='1' AND view='1'";
$result = $db->sql_query($sql);
while ($row = $db->sql_fetchrow($result)) {
$b_title = filter($row[title], "nohtml");
if (!empty($b_title)) {
echo "<li>"._ACCESSTO." $b_title\n";
}
}
if (is_active("Journal")) {
echo "<li>"._CREATEJOURNAL."\n";
}
if ($my_headlines == 1) {
echo "<li>"._READHEADLINES."\n";
}
echo "<li>"._ASREG7."\n"
."</ul>\n"
.""._REGISTERNOW."<br>\n"
.""._WEDONTGIVE."<br><br>\n"
."<center><font class=\"content\">[ <a href=\"modules.php?name=$module_name\">"._USERLOGIN."</a> | <a href=\"modules.php?name=$module_name&amp;op=pass_lost\">"._PASSWORDLOST."</a> ]</font></center>\n";
CloseTable();
include("footer.php");
} elseif (is_user($user)) {
global $cookie;
cookiedecode($user);
userinfo($cookie[1]);
}
}

function pass_lost() {
global $user, $module_name;
if (!is_user($user)) {
include("header.php");
OpenTable();
echo "<center><font class=\"title\"><b>"._USERREGLOGIN."</b></font></center>\n";
CloseTable();
echo "<br>\n";
OpenTable();
echo "<b>"._PASSWORDLOST."</b><br><br>\n"
.""._NOPROBLEM."<br><br>\n"
."<form action=\"modules.php?name=$module_name\" method=\"post\">\n"
."<table border=\"0\"><tr><td>\n"
.""._NICKNAME.":</td><td><input type=\"text\" name=\"username\" size=\"15\" maxlength=\"25\"></td></tr>\n"
."<tr><td>"._CONFIRMATIONCODE.":</td><td><input type=\"text\" name=\"code\" size=\"11\" maxlength=\"10\"></td></tr></table><br>\n"
."<input type=\"hidden\" name=\"op\" value=\"mailpasswd\">\n"
."<input type=\"submit\" value=\""._SENDPASSWORD."\"></form><br>\n"
."<center><font class=\"content\">[ <a href=\"modules.php?name=$module_name\">"._USERLOGIN."</a> | <a href=\"modules.php?name=$module_name&amp;op=new_user\">"._REGNEWUSER."</a> ]</font></center>\n";
CloseTable();
include("footer.php");
} elseif(is_user($user)) {
global $cookie;
cookiedecode($user);
userinfo($cookie[1]);
}
}

function logout() {
global $prefix, $db, $user, $cookie, $redirect;
cookiedecode($user);
$r_uid = $cookie[0];
$r_username = $cookie[1];
setcookie("user", false);
$db->sql_query("DELETE FROM ".$prefix."_session WHERE uname='$r_username'");
$db->sql_query("DELETE FROM ".$prefix."_bbsessions WHERE session_user_id='$r_uid'");
$user = "";
include("header.php");
OpenTable();
if (!empty($redirect)) {
echo "<META HTTP-EQUIV=\"refresh\" content=\"3;URL=modules.php?name=$redirect\">";
} else {
echo "<META HTTP-EQUIV=\"refresh\" content=\"3;URL=index.php\">";
}
echo "<center><font class=\"option\"><b>"._YOUARELOGGEDOUT."</b></font></center>";
CloseTable();
include("footer.php");
}

function mail_password($username, $code) {
global $nsnst_const, $sitename, $adminmail, $nukeurl, $user_prefix, $db, $module_name;
$username = filter($username, "nohtml", 1);
$username = substr($username, 0, 25);
$username = htmlspecialchars($username);
$sql = "SELECT user_email, user_password FROM ".$user_prefix."_users WHERE username='$username'";
$result = $db->sql_query($sql);
if($db->sql_numrows($result) == 0) {
include("header.php");
OpenTable();
echo "<center>"._SORRYNOUSERINFO."</center>";
CloseTable();
include("footer.php");
} else {
if(!defined("NUKESENTINEL_IS_LOADED")) {
$row = $db->sql_fetchrow($result);
$user_email = filter($row['user_email'], "nohtml");
$user_password = $row['user_password'];
$user_password = htmlspecialchars(stripslashes($user_password));
$areyou = substr($user_password, 0, 10);
if ($areyou==$code) {
$newpass=makepass();
$message = ""._USERACCOUNT." '$username' "._AT." $sitename "._HASTHISEMAIL." "._AWEBUSERFROM." $host_name "._HASREQUESTED."\n\n"._YOURNEWPASSWORD." $newpass\n\n "._YOUCANCHANGE." $nukeurl/modules.php?name=$module_name\n\n"._IFYOUDIDNOTASK."";
$subject = ""._USERPASSWORD4." $username";
mail($user_email, $subject, $message, "From: $adminmail\nX-Mailer: PHP/" . phpversion());
/* Next step: add the new password to the database */
$cryptpass = md5($newpass);
$query = "UPDATE ".$user_prefix."_users SET user_password='$cryptpass' WHERE username='$username'";
if (!$db->sql_query($query)) {
echo ""._UPDATEFAILED."";
}
include ("header.php");
OpenTable();
echo "<center>"._PASSWORD4." $username "._MAILED."<br><br>"._GOBACK."</center>";
CloseTable();
include ("footer.php");
/* If no Code, send it */
} else {
$sql = "SELECT user_email, user_password FROM ".$user_prefix."_users WHERE username='$username'";
$result = $db->sql_query($sql);
if($db->sql_numrows($result) == 0) {
include ("header.php");
OpenTable();
echo "<center>"._SORRYNOUSERINFO."</center>";
CloseTable();
include ("footer.php");
} else {
if(!defined("NUKESENTINEL_IS_LOADED")) {
$row = $db->sql_fetchrow($result);
$user_email = filter($row['user_email'], "nohtml");
$user_password = $row['user_password'];
$areyou = substr($user_password, 0, 10);
$message = ""._USERACCOUNT." '$username' "._AT." $sitename "._HASTHISEMAIL." "._AWEBUSERFROM." $host_name "._CODEREQUESTED."\n\n"._YOURCODEIS." $areyou \n\n"._WITHTHISCODE." $nukeurl/modules.php?name=$module_name&op=pass_lost\n"._IFYOUDIDNOTASK2."";
$subject=""._CODEFOR." $username";
mail($user_email, $subject, $message, "From: $adminmail\nX-Mailer: PHP/" . phpversion());
include ("header.php");
OpenTable();
echo "<center>"._CODEFOR." $username "._MAILED."<br><br>"._GOBACK."</center>";
CloseTable();
include ("footer.php");
}
}
}
}

function docookie($setuid, $setusername, $setpass, $setstorynum, $setumode, $setuorder, $setthold, $setnoscore, $setublockon, $settheme, $setcommentmax) {
$info = base64_encode&a
 
evaders99
PostPosted: Sat Feb 07, 2009 7:21 pm Reply with quote

Please use the "code" BBCode tags

You've only posted to line 836
We don't need the entire file. Probably just the 10 or so lines around line 882
 
scout
PostPosted: Sat Feb 07, 2009 7:30 pm Reply with quote

I didn't realize I only posted down to 836...I think the code below is the area with the problem.


name=\"user_email\" size=\"30\" maxlength=\"255\"></td></tr>\n"
."<tr><td>"._PASSWORD.":</td><td><input type=\"password\" name=\"user_password\" size=\"11\" maxlength=\"40\"></td></tr>\n"
."<tr><td>"._RETYPEPASSWORD.":</td><td><input type=\"password\" name=\"user_password2\" size=\"11\" maxlength=\"40\"><br><font class=\"tiny\">("._BLANKFORAUTO.")</font></td></tr>\n";
if (extension_loaded("gd") AND ($gfx_chk == 3 OR $gfx_chk == 4 OR $gfx_chk == 6 OR $gfx_chk == 7)) {
echo "<tr><td>"._SECURITYCODE.":</td><td><img src='?gfx=gfx&random_num=$random_num' border='1' alt='"._SECURITYCODE."' title='"._SECURITYCODE."'></td></tr>\n"
."<tr><td>"._TYPESECCODE.":</td><td><input type=\"text\" NAME=\"gfx_check\" SIZE=\"7\" MAXLENGTH=\"6\"></td></tr>\n"
."<input type=\"hidden\" name=\"random_num\" value=\"$random_num\">\n";
}
echo "<tr><td colspan='2'>\n"
."<input type=\"hidden\" name=\"op\" value=\"new user\">\n"
."<input type=\"submit\" value=\""._NEWUSER."\">\n"
."</td></tr></table>\n"
."</form>\n"
."<br>\n"
.""._YOUWILLRECEIVE."<br><br>\n"
.""._COOKIEWARNING."<br>\n"
.""._ASREGUSER."<br>\n"
."<ul>\n"
."<li>"._ASREG1."\n"
."<li>"._ASREG2."\n"
."<li>"._ASREG3."\n"
."<li>"._ASREG4."\n"
."<li>"._ASREG5."\n";
$handle=opendir('themes');
$thmcount = 0;
while ($file = readdir($handle)) {
if ((!ereg("[.]",$file) AND file_exists("themes/$file/theme.php"))) {
$thmcount++;
}
}
closedir($handle);
if ($thmcount > 1) {
echo "<li>"._ASREG6."\n";
}
$sql = "SELECT custom_title FROM ".$prefix."_modules WHERE active='1' AND view='1' AND inmenu='1'";
$result = $db->sql_query($sql);
while ($row = $db->sql_fetchrow($result)) {
$custom_title = filter($row[custom_title], "nohtml");
if (!empty($custom_title)) {
echo "<li>"._ACCESSTO." $custom_title\n";
}
}
$sql = "SELECT title FROM ".$prefix."_blocks WHERE active='1' AND view='1'";
$result = $db->sql_query($sql);
while ($row = $db->sql_fetchrow($result)) {
$b_title = filter($row[title], "nohtml");
if (!empty($b_title)) {
echo "<li>"._ACCESSTO." $b_title\n";
}
}
if (is_active("Journal")) {
echo "<li>"._CREATEJOURNAL."\n";
}
if ($my_headlines == 1) {
echo "<li>"._READHEADLINES."\n";
}
echo "<li>"._ASREG7."\n"
."</ul>\n"
.""._REGISTERNOW."<br>\n"
.""._WEDONTGIVE."<br><br>\n"
."<center><font class=\"content\">[ <a href=\"modules.php?name=$module_name\">"._USERLOGIN."</a> | <a href=\"modules.php?name=$module_name&amp;op=pass_lost\">"._PASSWORDLOST."</a> ]</font></center>\n";
CloseTable();
 
evaders99
PostPosted: Sat Feb 07, 2009 7:41 pm Reply with quote

I don't see anything obvious, but would be helpful to know which one is 882

Again, please use the BBCode "code" tags. That will help users looking at this post
 
Palbin
Site Admin


Joined: Mar 30, 2006
Posts: 2583
Location: Pittsburgh, Pennsylvania

PostPosted: Sat Feb 07, 2009 8:07 pm Reply with quote

Would probably be better to post a link to the file as this one is so big.

Evaders99, I tried adding bbcode to his first post before. There is something in there that doesn't allow bbcode to work.

_________________
"Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it." — Brian W. Kernighan. 
View user's profile Send private message
Display posts from previous:       
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> NukeSentinel™

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©