Peržiūrėti temą
PHP-Fusion Mods :: PHP-Fusion modifikacijų forumas :: Taisymas
|
v7 psjim sistema...
|
||||
| rimviz |
parašyta 2011-04-13 16:12
|
|||
|
Naujokas ![]() Reputacija: 0 Pranešimai: 7 Įstojo: 2010-11-23 |
Taigi parsisiuniau i? ?io tinkalpio snapso spjim sistem ir noriau kad pjimus rodytu ir forume. Taip yra dauk tem su tais kodais, bet nei vienas man neveikia, kame bda?.. Jai kas kaltu perdaryt ?tai kodas, bsu dkingas...
/*-------------------------------------------------------+
| PHP-Fusion Content Management System | Copyright (C) 2002 - 2010 Nick Jones | http://www.php-fusion.co.uk/ +--------------------------------------------------------+ | Filename: viewthread.php | Author: Nick Jones (Digitanium) +--------------------------------------------------------+ | This program is released as free software under the | Affero GPL license. You can redistribute it and/or | modify it under the terms of this license which you | can read by viewing the included agpl.txt or online | at www.gnu.org/licenses/agpl.html. Removal of this | copyright header is strictly prohibited without | written permission from the original author(s). +--------------------------------------------------------*/ require_once "../maincore.php"; require_once INCLUDES."forum_include.php"; require_once THEMES."templates/header.php"; include LOCALE.LOCALESET."forum/main.php"; $posts_per_page = 20; add_to_title($locale['global_200'].$locale['400']); if (!isset($_GET['thread_id']) || !isnum($_GET['thread_id'])) { redirect("index.php"); } if (!isset($_GET['rowstart']) || !isnum($_GET['rowstart'])) { $_GET['rowstart'] = 0; } $result = dbquery( "SELECT t.*, f.*, f2.forum_name AS forum_cat_name FROM ".DB_THREADS." t LEFT JOIN ".DB_FORUMS." f ON t.forum_id=f.forum_id LEFT JOIN ".DB_FORUMS." f2 ON f.forum_cat=f2.forum_id WHERE t.thread_id='".$_GET['thread_id']."' AND t.thread_hidden='0'" ); if (dbrows($result)) { $fdata = dbarray($result); if (!checkgroup($fdata['forum_access']) || !$fdata['forum_cat'] || $fdata['thread_hidden'] == "1") { redirect("index.php"); } } else { redirect("index.php"); } if ($fdata['forum_post'] != 0 && checkgroup($fdata['forum_post'])) { $can_post = true; } else { $can_post = false; } if ($fdata['forum_reply'] != 0 && checkgroup($fdata['forum_reply'])) { $can_reply = true; } else { $can_reply = false; } if ($settings['forum_edit_lock'] == 1) { $lock_edit = true; } else { $lock_edit = false; } //locale dependent forum buttons if (is_array($fusion_images)) { if ($settings['locale'] != "English") { $newpath = ""; $oldpath = explode("/", $fusion_images['newthread']); for ($i = 0; $i < count($oldpath) - 1; $i++) { $newpath .= $oldpath[$i]."/"; } if (is_dir($newpath.$settings['locale'])) { redirect_img_dir($newpath, $newpath.$settings['locale']."/"); } } } //locale dependent forum buttons $mod_groups = explode(".", $fdata['forum_moderators']); if (iSUPERADMIN) { define("iMOD", true); } if (!defined("iMOD") && iMEMBER && $fdata['forum_moderators']) { foreach ($mod_groups as $mod_group) { if (!defined("iMOD") && checkgroup($mod_group)) { define("iMOD", true); } } } if (!defined("iMOD")) { define("iMOD", false); } if (iMOD && (((isset($_POST['delete_posts']) || isset($_POST['move_posts'])) && isset($_POST['delete_post'])) || isset($_GET['error']))) { require_once FORUM."viewthread_options.php"; } $user_field = array("user_sig" => false, "user_web" => false); if (iMEMBER) { $thread_match = $fdata['thread_id']."\|".$fdata['thread_lastpost']."\|".$fdata['forum_id']; if (($fdata['thread_lastpost'] > $lastvisited) && !preg_match("(^\.{$thread_match}$|\.{$thread_match}\.|\.{$thread_match}$)", $userdata['user_threads'])) { $result = dbquery("UPDATE ".DB_USERS." SET user_threads='".$userdata['user_threads'].".".stripslashes($thread_match)."' WHERE user_id='".$userdata['user_id']."'"); } if (isset($userdata['user_sig'])) { $user_field['user_sig'] = true; } if (isset($userdata['user_web'])) { $user_field['user_web'] = true; } if (isset($_POST['cast_vote']) && (isset($_POST['poll_option']) && isnum($_POST['poll_option']))) { $result = dbquery("SELECT forum_vote_user_id FROM ".DB_FORUM_POLL_VOTERS." WHERE forum_vote_user_id='".$userdata['user_id']."' AND thread_id='".$_GET['thread_id']."'"); if (!dbrows($result)) { $result = dbquery("UPDATE ".DB_FORUM_POLL_OPTIONS." SET forum_poll_option_votes=forum_poll_option_votes+1 WHERE thread_id='".$_GET['thread_id']."' AND forum_poll_option_id='".$_POST['poll_option']."'"); $result = dbquery("UPDATE ".DB_FORUM_POLLS." SET forum_poll_votes=forum_poll_votes+1 WHERE thread_id='".$_GET['thread_id']."'"); $result = dbquery("INSERT INTO ".DB_FORUM_POLL_VOTERS." (thread_id, forum_vote_user_id, forum_vote_user_ip) VALUES ('".$_GET['thread_id']."', '".$userdata['user_id']."', '".USER_IP."')"); } redirect(FUSION_SELF."?thread_id=".$_GET['thread_id']); } } else { $result = dbquery("SELECT field_name FROM ".DB_USER_FIELDS." WHERE field_name='user_sig' OR field_name='user_web'"); while ($data = dbarray($result)) { $user_field[$data['field_name']] = true; } } if (isset($_GET['pid']) && isnum($_GET['pid'])) { $reply_count = dbcount("(post_id)", DB_POSTS, "thread_id='".$fdata['thread_id']."' AND post_id<='".$_GET['pid']."' AND post_hidden='0'"); if ($reply_count > $posts_per_page) { $_GET['rowstart'] = ((ceil($reply_count / $posts_per_page)-1) * $posts_per_page); } } $caption = $fdata['forum_cat_name']." ".$fdata['forum_name'].""; list($rows, $last_post) = dbarraynum(dbquery( "SELECT COUNT(post_id), MAX(post_id) FROM ".DB_POSTS." WHERE thread_id='".$_GET['thread_id']."' AND post_hidden='0' GROUP BY thread_id")); opentable($locale['500']); echo " ".$settings['sitename']." ".$caption." \n";if (($rows > $posts_per_page) || ($can_post || $can_reply)) { echo "
} if ($rows != 0) { dbquery("UPDATE ".DB_THREADS." SET thread_postcount='$rows', thread_lastpostid='$last_post', thread_views=thread_views+1 WHERE thread_id='".$_GET['thread_id']."'"); if ($_GET['rowstart'] == 0 && $fdata['thread_poll'] == "1") { if (iMEMBER) { $presult = dbquery( "SELECT tfp.forum_poll_title, tfp.forum_poll_votes, tfv.forum_vote_user_id FROM ".DB_FORUM_POLLS." tfp LEFT JOIN ".DB_FORUM_POLL_VOTERS." tfv ON tfp.thread_id=tfv.thread_id AND forum_vote_user_id='".$userdata['user_id']."' WHERE tfp.thread_id='".$_GET['thread_id']."'" ); } else { $presult = dbquery( "SELECT tfp.forum_poll_title, tfp.forum_poll_votes FROM ".DB_FORUM_POLLS." tfp WHERE tfp.thread_id='".$_GET['thread_id']."'" ); } if (dbrows($presult)) { $pdata = dbarray($presult); $i = 1; if (iMEMBER) { echo "\n"; } } } $result = dbquery( "SELECT p.forum_id, p.thread_id, p.post_id, p.post_message, p.post_showsig, p.post_smileys, p.post_author, p.post_datestamp, p.post_ip, p.post_edituser, p.post_edittime, fa.attach_id, fa.attach_name, fa.attach_ext, fa.attach_size, u.user_id, u.user_name, u.user_status, u.user_avatar, u.user_level, u.user_posts, u.user_groups, u.user_joined, ".($user_field['user_sig'] ? " u.user_sig," : "").($user_field['user_web'] ? " u.user_web," : "")." u2.user_name AS edit_name, u2.user_status AS edit_status FROM ".DB_POSTS." p LEFT JOIN ".DB_FORUM_ATTACHMENTS." fa USING(post_id) LEFT JOIN ".DB_USERS." u ON p.post_author = u.user_id LEFT JOIN ".DB_USERS." u2 ON p.post_edituser = u2.user_id AND post_edituser > '0' WHERE p.thread_id='".$_GET['thread_id']."' AND post_hidden='0' ORDER BY post_datestamp LIMIT ".$_GET['rowstart'].",$posts_per_page" ); if (iMOD) { echo "\n"; } if ($rows > $posts_per_page) { echo " \n"; \n";echo makePageNav($_GET['rowstart'],$posts_per_page,$rows,3,FUSION_SELF."?thread_id=".$_GET['thread_id'].(isset($_GET['highlight']) ? "&highlight=".urlencode($_GET['highlight']):"")."&")."\n"; echo " } $forum_list = ""; $current_cat = ""; $result = dbquery( "SELECT f.forum_id, f.forum_name, f2.forum_name AS forum_cat_name FROM ".DB_FORUMS." f INNER JOIN ".DB_FORUMS." f2 ON f.forum_cat=f2.forum_id WHERE ".groupaccess('f.forum_access')." AND f.forum_cat!='0' ORDER BY f2.forum_order ASC, f.forum_order ASC" ); while ($data = dbarray($result)) { if ($data['forum_cat_name'] != $current_cat) { if ($current_cat != "") { $forum_list .= "\n"; } $current_cat = $data['forum_cat_name']; $forum_list .= "\n"; if (iMOD) { echo "\n"; } if ($can_post || $can_reply) { echo "
} closetable(); if ($can_reply && !$fdata['thread_locked']) { require_once INCLUDES."bbcode_include.php"; opentable($locale['512']); echo "\n"; closetable(); } echo "\n"; require_once THEMES."templates/footer.php"; ?> http://goovernoor... RSPS skirtas tik mkstantiem bendrauti :) |
|||
| MrChiliz |
parašyta 2011-04-13 18:37
|
|||
|
Pradinukas ![]() Reputacija: 0 Pranešimai: 31 Įstojo: 2011-01-01 |
man buvo toke pati problema su ta pacia sistema. profile.php faile visus field_group pakeisk i field_cat ju ten turetu buti trys. | |||
| rimviz |
parašyta 2011-04-14 13:24
|
|||
|
Naujokas ![]() Reputacija: 0 Pranešimai: 7 Įstojo: 2010-11-23 |
O tai pakeisiu ir rodys forume tipo? Man rods visi?kai nusi?nekjai, nes ?itas pataiso visai kitk. Man reik kad forume rodytu ne profile blmb... Redagavo rimviz 2011-04-14 13:26 http://goovernoor... RSPS skirtas tik mkstantiem bendrauti :) |
|||
| minimukas |
parašyta 2011-04-14 15:16
|
|||
|
Moderatorius ![]() Reputacija: 0 Pranešimai: 602 Įstojo: 2009-06-11 |
Isiterpk i norima vieta: www.nusirasinek.lt - Pratybų atsakymai |
|||
| rimviz |
parašyta 2011-04-15 09:25
|
|||
|
Naujokas ![]() Reputacija: 0 Pranešimai: 7 Įstojo: 2010-11-23 |
Nepadeda ir dar webas kaire nueina :O..
http://goovernoor... RSPS skirtas tik mkstantiem bendrauti :) |
|||
| SysRq |
parašyta 2011-04-15 10:48
|
|||
|
Savekas ![]() Reputacija: 0 Pranešimai: 137 Įstojo: 2011-04-09 |
Tai gal ne t viet djai. | |||
| minimukas |
parašyta 2011-04-15 11:04
|
|||
|
Moderatorius ![]() Reputacija: 0 Pranešimai: 602 Įstojo: 2009-06-11 |
LaraX turi padet kodas yra geras.... kaip sysasrq sako tikrai ne i ta vieta tikriausiai idejai... www.nusirasinek.lt - Pratybų atsakymai |
|||
| rimviz |
parašyta 2011-04-15 12:04
|
|||
|
Naujokas ![]() Reputacija: 0 Pranešimai: 7 Įstojo: 2010-11-23 |
?inau kad geras. Bet tai koki viet reikia dti? Nelb nusimanau su tuo PHP.... Tiksliau su tais kodais :( Va sidjau t eilute po forum ranks i?mete: Nario a33;spa33;jimai:
Fatal error: Call to undefined function getWarnings() in /usr/home/www1/ftp/laraxas/forum/viewthread.php on line 255 Redagavo rimviz 2011-04-15 12:11 http://goovernoor... RSPS skirtas tik mkstantiem bendrauti :) |
|||
| Wyciokazz |
parašyta 2011-04-15 13:07
|
|||
|
Administratorius ![]() Reputacija: 1 Pranešimai: 2108 Įstojo: 2008-02-27 |
Pasiknisk mano profilyje rasi kazkur buvau imetes veikiancia sistema v3 ispejimu.
Kam kurti tai kas jau sukurta. Nesu ekstrasensas ar dar koks čigonas tad iš nieko negaliu suprast kur bėda. [img]http://27.media.tumblr.com/tumblr_m3hdwudgjG1rteofuo1_500.gif[/img] |
|||
| Peršokti į forumą: |








