Aisku dabar tokie laikai, kai turinio valdymo sistemas valdome one-click principu. Ne kaip seniau kode ieskodavom klaidu, norint moda pasileist.. :D paciam reikdavo susidiegt viska i ftp..
Turiu toki problema jog noriu idti VIP paveiksliuk comments_include.php fail.ia tam kad para?ius komentar matytusi ar narys yra VIP ar ne.
Dedu ?ituos kodus taiau ka?kodl nerodo man,nors narys ir yra VIP.
$vip = \"
http://nuoroda.lt/images/vip.jpg' border='0' alt='VIP' border='0' title='Šis narys naudojasi VIP paslauga'>\";
/*---------------------------------------------------+
| PHP-Fusion 6 Content Management System
+----------------------------------------------------+
| Copyright 2002 - 2006 Nick Jones
| http://www.php-fusion.co.uk/
+----------------------------------------------------+
| Released under the terms & conditions of v2 of the
| GNU General Public License. For details refer to
| the included gpl.txt file or visit http://gnu.org
+----------------------------------------------------+
| Created for PHP-FUSION 6.01.12
| 2007 by AlexALX
| http://www.alexalx-soft.com/
+----------------------------------------------------*/
/*
Created for PHP-FUSION 6.01.12
2007 by AlexALX
http://www.alexalx-soft.com/
*/
if (!defined(\"IN_FUSION\")) { header(\"Location:../index.php\"); exit; }
include LOCALE.LOCALESET.\"comments.php\";
function make_codes0_captcha() {
global $settings;
srand((double)microtime() * 1000000);
$temp_num = md5(rand(0,9999));
$captcha_string = substr($temp_num, 17, 5);
$captcha_encode = md5($temp_num);
$result = mysql_query(\"INSERT INTO \".DB_PREFIX.\"captcha (captcha_datestamp, captcha_ip, captcha_encode, captcha_string) VALUES('\".time().\"', '\".USER_IP.\"', '$captcha_encode', '$captcha_string')\");
$result = dbquery(\"SELECT * FROM \".DB_PREFIX.\"comments_settings\");
$data = dbarray($result);
if ($data['code1'] == \"0\") {
return \"\n\";
} else {
return \"\".$captcha_string.\"\n\";
}
}
function check_captcha_cods($captchs_encode, $captcha_string) {
if (preg_match(\"/^[0-9a-z]+$/\", $captchs_encode) && preg_match(\"/^[0-9a-z]+$/\", $captcha_string)) {
$result = dbquery(\"SELECT * FROM \".DB_PREFIX.\"captcha WHERE captcha_ip='\".USER_IP.\"' AND captcha_encode='\".$captchs_encode.\"' AND captcha_string='\".$captcha_string.\"'\");
if (dbrows($result)) {
$result = dbquery(\"DELETE FROM \".DB_PREFIX.\"captcha WHERE captcha_ip='\".USER_IP.\"' AND captcha_encode='\".$captchs_encode.\"' AND captcha_string='\".$captcha_string.\"'\");
return true;
} else {
return false;
}
} else {
return false;
}
}
if ($post1 == \"3\") {
if (isset($_POST['post_comment'])) {
if (iMEMBER) {
if (!check_captcha_cods($_POST['captcha_encode'], $_POST['captcha_code'])) {
$error .= $locale['c108'].\" \n\";
} else {
//$error = \"\";
//$error = $locale['c108'].\" \n\";
$flood = false;
if (dbrows(dbquery(\"SELECT $ccol FROM \".DB_PREFIX.\"$cdb WHERE $ccol='$cid'\"))==0) {
fallback(BASEDIR.\"index.php\");
}
$comment_name = $userdata['user_id'];
//$comment_name = trim(stripinput($_POST['comment_name']));
// $comment_name = preg_replace(\"(^[0-9]*)\", \"\", $comment_name);
//if (isNum($comment_name)) $comment_name=\"\";
$comment_message = trim(stripinput(censorwords($_POST['comment_message'])));
$comment_smileys = isset($_POST['disable_smileys']) ? \"0\" : \"1\";
if ($comment_name != \"\" && $comment_message != \"\") {
$result = dbquery(\"SELECT MAX(comment_datestamp) AS last_comment FROM \".DB_PREFIX.\"comments WHERE comment_ip='\".USER_IP.\"'\");
if (!iSUPERADMIN || dbrows($result) > 0) {
$data = dbarray($result);
if ((time() - $data['last_comment']) < $settings['flood_interval']) {
$flood = true;
$result = dbquery(\"INSERT INTO \".DB_PREFIX.\"flood_control (flood_ip, flood_timestamp) VALUES ('\".USER_IP.\"', '\".time().\"')\");
if (dbcount(\"(flood_ip)\", \"flood_control\", \"flood_ip='\".USER_IP.\"'\") > 4) {
if (iMEMBER) $result = dbquery(\"UPDATE \".$db_prefix.\"users SET user_status='1' WHERE user_id='\".$userdata['user_id'].\"'\");
}
}
}
if (!$flood) $result = dbquery(\"INSERT INTO \".DB_PREFIX.\"comments (comment_item_id, comment_type, comment_name, comment_message, comment_smileys, comment_datestamp, comment_ip) VALUES ('$cid', '$ctype', '$comment_name', '$comment_message', '$comment_smileys', '\".time().\"', '\".USER_IP.\"')\");
} redirect($clink);
tablebreak();
}
}
}
}
} else {
if (isset($_POST['post_comment'])) {
$flood = false;
if (dbrows(dbquery(\"SELECT $ccol FROM \".DB_PREFIX.\"$cdb WHERE $ccol='$cid'\"))==0) {
fallback(BASEDIR.\"index.php\");
}
if (iGUEST) {
$comment_name = preg_replace(\"(^[0-9]*)\", \"\", $comment_name);
if (isNum($comment_name)) $comment_name=\"\";
} else {
$comment_name = $userdata['user_id'];
}
$comment_message = trim(stripinput(censorwords($_POST['comment_message'])));
$comment_smileys = isset($_POST['disable_smileys']) ? \"0\" : \"1\";
if ($comment_name != \"\" && $comment_message != \"\") {
$result = dbquery(\"SELECT MAX(comment_datestamp) AS last_comment FROM \".DB_PREFIX.\"comments WHERE comment_ip='\".USER_IP.\"'\");
if (!iSUPERADMIN || dbrows($result) > 0) {
$data = dbarray($result);
if ((time() - $data['last_comment']) < $settings['flood_interval']) {
$flood = true;
$result = dbquery(\"INSERT INTO \".DB_PREFIX.\"flood_control (flood_ip, flood_timestamp) VALUES ('\".USER_IP.\"', '\".time().\"')\");
if (dbcount(\"(flood_ip)\", \"flood_control\", \"flood_ip='\".USER_IP.\"'\") > 4) {
if (iMEMBER) $result = dbquery(\"UPDATE \".$db_prefix.\"users SET user_status='1' WHERE user_id='\".$userdata['user_id'].\"'\");
}
}
}
if (!$flood) $result = dbquery(\"INSERT INTO \".DB_PREFIX.\"comments (comment_item_id, comment_type, comment_name, comment_message, comment_smileys, comment_datestamp, comment_ip) VALUES ('$cid', '$ctype', '$comment_name', '$comment_message', '$comment_smileys', '\".time().\"', '\".USER_IP.\"')\");
paygold($userdata['user_name'],$userdata['user_id'],1);
} redirect($clink);
tablebreak();
}
}
opentable($locale['c100']);
$result = dbquery(
\"SELECT tcm.*,user_name,user_avatar,enable_kod,enable_post,enable_avatar,post1,code1 FROM \".DB_PREFIX.\"comments tcm
LEFT JOIN \".DB_PREFIX.\"users tcu ON tcm.comment_name=tcu.user_id
LEFT JOIN \".DB_PREFIX.\"comments_settings ON
enable_kod=enable_kod
AND enable_post=enable_post
AND enable_avatar=enable_avatar
AND post1=post1
AND code1=code1
WHERE comment_item_id='$cid' AND comment_type='$ctype'
ORDER BY comment_datestamp ASC\"
);
if (dbrows($result) != 0) {
$i = 0;
echo \"
\n\";
while ($data = dbarray($result)) {
if ($data['enable_avatar'] == \"1\") {
if ($data['user_avatar'] != \"\") {
$avatar = \"
Dabar jau nebagaliu perdaryti grup ,nes kitur yra ir pana?iai padaryta, o vl persidaryti visk u?imt nema?ai laiko.Tad reikt kad kasnors padt i?sprsti ?i problem ??
http://topwarez.lt