Hi.
Danke Dir!
Würde ich damit dann die ID 203 ausschließen aus der Benachrichtigung? Es soll ja nur die eine Kategorie keine Benachrichtigung senden.
Edit: Habs gerade mal eingebaut. Nein, funktioniert leider nicht. Lege ich in der Kategorie 203 (Chefredaktion) einen Thread an, so wird dennoch eine Emailbenachrichtigung versandt.
Aktuell sieht meine newpost.php nun so aus:
Hier klicken für weitere Informationen
Danke Dir!
Würde ich damit dann die ID 203 ausschließen aus der Benachrichtigung? Es soll ja nur die eine Kategorie keine Benachrichtigung senden.
Edit: Habs gerade mal eingebaut. Nein, funktioniert leider nicht. Lege ich in der Kategorie 203 (Chefredaktion) einen Thread an, so wird dennoch eine Emailbenachrichtigung versandt.
Aktuell sieht meine newpost.php nun so aus:
|
|
PHP-Quelltext |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 |
<?php
include("forum/kopf.php");
unset($cat_option);
if ($config['forum_doublepost']!=1 && $threadid>0 && $USER['id']>0) $doublepostinfo=$DB->fetch_array($DB->query("SELECT forumpost_id, forumpost_autorid FROM ".$db_tab['forumpost']." WHERE forumpost_threadid='".$threadid."' ORDER by forumpost_time DESC LIMIT 1"));
if ($threadid==0 && $catid==0) {
if (is_array($forumcat_cache)) {
foreach ($forumcat_cache_byname as $selectcat) {
if ((userrights($selectcat['forumcat_mods'])=="true" || userrights($selectcat['forumcat_user'])=="true" || getrights($selectcat['forumcat_trights'])=="true") && $selectcat['forumcat_status']==1 && $selectcat['forumcat_threads_option']==1) $cat_option.='<option value="'.$selectcat['forumcat_id'].'">'.$selectcat['forumcat_name'].'</option>';
}
if ($cat_option) eval ("\$cat_option= \"".getTemplate("forum/newpost_cat_option")."\";");
}
}
if ($catid>0 && ($forumcat['forumcat_threads_option']!=1 || $forumcat['forumcat_status']!=1)) {$event=37; include("admin/config/event.php");}
elseif (($catid==0 || !$catid) && ($threadid==0 || !$threadid) && !$cat_option) {$event=1; include("admin/config/event.php");}
elseif ($threadid!=0 && $config['forum_doublepost']!=1 && $user_id==$doublepostinfo[forumpost_autorid] && $user_id!=0) {$event=38; include("admin/config/event.php");}
elseif ($threadid!=0 && ($forumthread['forumthread_status']==0 or $forumthread[forumthread_status]==3)) {$event=36; include("admin/config/event.php");}
elseif (($catid!=0 && (userrights($forumcat['forumcat_mods'])=="true" || userrights($forumcat['forumcat_user'])=="true" || getrights($forumcat['forumcat_trights'])=="true")) || ($catid==0 && $threadid==0 && $cat_option!='') || ($threadid!=0 && (getrights($forumcat[forumcat_wrights])=="true" || userrights($forumcat['forumcat_mods'])=="true" || userrights($forumcat['forumcat_user'])=="true"))) {
if (isset($_POST['action'])) $ACTION=$_POST['action'];
else $ACTION='view';
if ($ACTION==$_POST['save'] || $ACTION==$_POST['preview']) {
if (trim($_POST['content'])!='') $post_text=$_POST['content'];
else unset($ACTION);
if (!$_POST['threadid'] && trim($_POST['post_title'])!='') $post_title=$_POST['post_title'];
elseif (!$_POST['threadid']) unset($ACTION);
if ($USER['id']>0) $post_autor=replacehtmlentities($USER['nick']);
elseif ($USER['id']==0 && trim($_POST['post_autor'])!='' && checkusername($_POST['post_autor'],1)) $post_autor=$_POST['post_autor'];
elseif ($USER['id']==0) {
$post_autor=$_POST['post_autor'];
unset($ACTION);
}
# KNS V2 | Idee: Onkel Hotte | Umsetzung: Headless (kitnetwork.de)
if(!$CAPTCHA->validCode($_POST['inputchars']) && $ACTION!=$_POST['preview'] && !getrights('user')) unset($ACTION);
# EOS
}
// Anfang Erweiterung Email mit IP u.a von arras //
$post_xxip=$thisUSER['ipaddr'];
$post_xxbrowser=$thisUSER['browser'];
$post_xxhost=gethostbyaddr($_SERVER['REMOTE_ADDR']);
$post_xxbz='Neuer Forenbeitrag';
// Ende Erweiterung Email mit IP u. a von arras//
if($_POST['vote_option']) $vote_option = $_POST['vote_option'];
unset($delvoteoption);
if($_POST['post_vote'] && is_array($vote_option))
{
foreach ($vote_option as $vote_option_single) {
if($vote_option_single == "") $delvoteoption = "1";
}
}
if($_POST['post_vote']==1 && ($forumcat['forumcat_voteoption']=="0" || !getrights($forumcat['forumcat_voteoption']))) unset($_POST['post_vote']);
if($_POST['post_vote']==1 && ($ACTION != $_POST['preview'] && (!is_array($vote_option) || count($vote_option) < 2)) || $_POST['vote_option_new'] != "" || $delvoteoption) $ACTION = "addvote";
if ($ACTION==$_POST['save'] && (isset($_POST['threadid']) || isset($_POST['catid']))) {
$check_time=time()-1800;
$DB->query("UPDATE ".$db_tab['forumpost']." SET forumpost_uid='' WHERE forumpost_time<'".$check_time."'");
$postuid=$DB->fetch_array($DB->query("SELECT COUNT(*) FROM ".$db_tab['forumpost']." WHERE forumpost_uid='".$_POST['post_uid']."' AND forumpost_time>'".$check_time."' LIMIT 1"));
if ($postuid[0]==0) {
unset($update_threadcount);
if ($threadid>0) $DB->query("UPDATE ".$db_tab['forumthread']." SET forumthread_replycount=forumthread_replycount+1, forumthread_lastreply_autor='".$_POST['post_autor']."',forumthread_lastreply_time='".time()."',forumthread_lastreply_autorid='".$USER['id']."' WHERE forumthread_id='".$threadid."'");
else {
if($_POST['post_vote']==1) { $votestatus = "1"; } else $votestatus = "0";
$DB->query("INSERT INTO ".$db_tab['forumthread']." (forumthread_autor,forumthread_autorid,forumthread_catid,forumthread_icon,forumthread_title,forumthread_lastreply_time,forumthread_lastreply_autor,forumthread_lastreply_autorid,forumthread_votetitle,forumthread_votestatus,forumthread_voterights,forumthread_votemultiple,forumthread_votehideresult,forumthread_voteshowtoall) VALUES ('".$_POST['post_autor']."','".$USER['id']."','".$catid."','".$_POST['post_icon']."','".addslashes($_POST['post_title'])."','".time()."','".$_POST['post_autor']."','".$USER['id']."','".addslashes($_POST['post_vote_title'])."','".$votestatus."','".$_POST['vote_rights']."','".$_POST['post_vote_multiple']."','".$_POST['post_vote_hideresult']."','".$_POST['post_vote_showtoall']."')");
$threadid=$DB->insert_id();
$update_threadcount=", forumcat_threadcount=forumcat_threadcount+1";
//Emailerweiterung von arras//
$post_xxbz='Neues Thema'; //Emailerweiterung von arras//
//Emailerweiterung von arras//
}
if (is_array($vote_option)) {
if (is_array($vote_option) && $post_vote_title=="") $post_vote_title=$post_title;
foreach ($vote_option as $vote_option_single) {
if ($vote_option_single!="") $DB->query("INSERT INTO ".$db_tab['forumvote']." (forumvote_threadid,forumvote_answer) VALUES ('".$threadid."','".addslashes($vote_option_single)."')");
}
}
$sqlcommand="forumcat_id='".$catid."'";
$id=$forumcat_cache[$catid]['forumcat_subcat'];
if ($id>0) {
while($id>0) {
$sqlcommand.=" OR forumcat_id='".$id."'";
$id=$forumcat_cache[$id]['forumcat_subcat'];
}
}
$DB->query("UPDATE ".$db_tab['forumcat']." SET forumcat_postcount=forumcat_postcount+1 ".$update_threadcount.",forumcat_lastreply_time='".time()."',forumcat_lastreply_threadid='".$threadid."',forumcat_lastreply_autor='".$_POST['post_autor']."',forumcat_lastreply_autorid='".$USER['id']."' WHERE ".$sqlcommand);
$DB->query("INSERT INTO ".$db_tab['forumpost']." (forumpost_threadid, forumpost_autor, forumpost_autorid, forumpost_icon, forumpost_title, forumpost_text, forumpost_time, forumpost_bbcode, forumpost_smilies, forumpost_uid, forumpost_ipaddr, forumpost_reply) VALUES ('".$threadid."','".$_POST['post_autor']."','".$USER['id']."','".$_POST['post_icon']."','".addslashes($_POST['post_title'])."','".addslashes($_POST['content'])."','".time()."','".$_POST['post_bbcode']."','".$_POST['post_smilies']."','".$_POST['post_uid']."','".$thisUSER['ipaddr']."','".$_POST['replyto']."')");
$postid=$DB->insert_id();
if ($USER['id']>0) {
$userposts=$DB->fetch_array($DB->query("SELECT COUNT(*) FROM ".$db_tab['forumpost']." WHERE forumpost_autorid='".$USER['id']."'"));
$DB->query("UPDATE ".$db_tab['user']." SET user_posts='".$userposts[0]."' WHERE user_id='".$USER['id']."'");
if ($config['ps_fa']==1) {
$DB->query("UPDATE ".$db_tab['user']." SET user_points=user_points+'".$config['ps_fn']."' WHERE user_id='".$USER['id']."'");
}
}
}
if ($USER['id']>0) $exception=" AND forumnotify_userid!='".$USER['id']."'";
else unset($exception);
unset($mailhash);
unset($sqlcommand);
$getnotify=$DB->query("SELECT forumnotify_email, forumnotify_userid FROM ".$db_tab['forumnotify']." WHERE forumnotify_threadid='".$threadid."' ".$exception);
while ($notify=$DB->fetch_array($getnotify)) {
if ($notify['forumnotify_userid']>0) {
if ($sqlcommand) $sqlcommand.=" OR user_id='".$notify['forumnotify_userid']."'";
else $sqlcommand="SELECT user_email FROM ".$db_tab['user']." WHERE user_id='".$notify['forumnotify_userid']."'";
}
else $mailhash[$notify['forumnotify_email']]=$notify['forumnotify_email'];
}
if ($sqlcommand) {
$getmails=$DB->query($sqlcommand);
while ($userinfo=$DB->fetch_array($getmails)) {
$mailhash[$userinfo['user_email']]=$userinfo['user_email'];
}
}
$forumthread=$DB->fetch_array($DB->query("SELECT forumthread_title FROM ".$db_tab['forumthread']." WHERE forumthread_id='".$threadid."' LIMIT 1"));
$mail_title=$config['site_urls'].' - '.$post_xxbz.': '.$forumthread['forumthread_title'].' Forum: '.$catid.'-';
eval ("\$mail_text= \"".getTemplate("forum/newpost_mail_notify_1")."\";"); // _1 = Emailerweiterung mit IP von arras//
notifymail('forum',$mail_title,$mail_text);
$im_title=$lang['new_post'].' '.$_POST['post_title'];
eval ("\$im_text= \"".getTemplate("forum/newpost_im_notify")."\";");
notifyim('forum',$im_title,$im_text);
if (is_array($mailhash)) {
$mail_title=$config['site_urls'].' - '.$lang['new_post'].': '.$forumthread['forumthread_title'];
eval ("\$mail_text= \"".getTemplate("forum/newpost_mail_text")."\";");
if($catid != '203') {
foreach ($mailhash as $email) {
mailsender($email,$mail_title,$mail_text);
}
}
}
if($_POST['post_notify'] == '1' && $threadid > '0' && $catid != '203') {
if ($USER['id']>0) $post_email=$USER['email'];
else $post_email=$_POST['post_email'];
if (emailcheck($post_email)) $DB->query("INSERT INTO ".$db_tab['forumnotify']." (forumnotify_userid,forumnotify_email,forumnotify_threadid) VALUES ('".$USER['id']."','".$post_email."','".$threadid."')");
}
header("location: include.php?path=forum/showthread.php&threadid=".$threadid."&postid=".$postid."&PHPKITSID=".session_id()."#post".$postid); exit();
}
else {
if ($ACTION==$_POST['preview']) {
$row='odd';
if ($_POST['post_icon']!='') {
$post_icon="icons/".$_POST['post_icon'];
eval ("\$post_icon= \"".getTemplate("forum/showthread_row_posticon")."\";");
}
$post_time=formattime();
$post_autor=htmlentities($post_autor);
$post_title=htmlentities(stripslashes($post_title));
# html 4 admins
// alt -> $post_text=$PARSE->parse($_POST['content'],0,$_POST['post_bbcode'],$_POST['post_smilies'],$config['forum_images'],1);
$post_text=$PARSE->parse($_POST['content'],(($PARSE->getHTMLPermission('admin', $_POST['content'])) ? 1 : 0),$_POST['post_bbcode'],$_POST['post_smilies'],$config['forum_images'],1,$config['hidden_form_aktiv']);
# / html 4 admins
eval ("\$preview_row= \"".getTemplate("forum/showthread_row")."\";");
eval ("\$site_body.= \"".getTemplate("forum/newpost_preview")."\";");
}
elseif ($ACTION!='view') {
unset($error_message);
if ($post_text=='') eval ("\$error_message.= \"".getTemplate("forum/newpost_error_text")."\";");
if (!$threadid && $post_title=="") eval ("\$error_message.= \"".getTemplate("forum/newpost_error_title")."\";");
if ($post_autor=='') eval ("\$error_message= \"".getTemplate("forum/newpost_error_autor")."\";");
# KNS V2 | Idee: Onkel Hotte | Umsetzung: Headless (kitnetwork.de)
if(!$CAPTCHA->validCode($_POST['inputchars']) && !getrights('user')) eval ("\$error_message.= \"".getTemplate("forum/newpost_error_captcha")."\";");
# EOS
elseif (!checkusername($_POST['post_autor'],1)) eval ("\$error_message= \"".getTemplate("forum/newpost_error_name")."\";");
if($ACTION == "addvote" && isset($_POST['post_vote_title']) && trim($_POST['post_vote_title'])=="") $error_message .= "• Umfrage: Bitte geben Sie die Frage an.<br />";
if($ACTION == "addvote" && (isset($option_vote) OR isset($_POST['vote_option_new'])) && ((count($vote_option) < 1 && $_POST['vote_option_new']!="") || (count($vote_option) < 2 && $_POST['vote_option_new']==""))) $error_message .= "• Umfrage: Sie müssen mindestens 2 Antwortmöglichkeiten angeben.<br />";
if ($error_message) eval ("\$post_error= \"".getTemplate("forum/newpost_error")."\";");
}
if (intval($_REQUEST['quote'])>0) {
if ($forumpost=$DB->fetch_array($DB->query("SELECT forumpost_text, forumpost_title, forumpost_autor FROM ".$db_tab['forumpost']." WHERE forumpost_id='".$_REQUEST['quote']."' AND forumpost_threadid='".$threadid."' LIMIT 1"))) {
$replyto=$_REQUEST['replyto'];
$post_title='RE: '.htmlentities($forumpost['forumpost_title']);
$post_text='[quote][i]'.$lang['original_written_by'].' '.$forumpost['forumpost_autor']."[/i]\n\n".htmlentities(stripslashes($forumpost['forumpost_text'])).'[/quote]';
/**************************************** HIDDEN_HACK Anfang ****************************************/
require_once('admin/lib/hidden.php');
$PARSEQUOTE=new PARSEQUOTE();
$post_text=$PARSEQUOTE->parsequote($post_text);
/**************************************** HIDDEN_HACK Ende ****************************************/
}
}
elseif (isset($_POST['replyto'])) $replyto=$_POST['replyto'];
else {
if ($forumpost=$DB->fetch_array($DB->query("SELECT forumpost_title FROM ".$db_tab['forumpost']." WHERE forumpost_threadid='".$threadid."' LIMIT 1"))) {
$post_title='re: '.htmlentities(eregi_replace('^re: *','',$forumpost['forumpost_title']));
}
}
if ($USER['id']>0) {
eval ("\$user_info= \"".getTemplate("forum/newpost_user")."\";");
}
else {
if ($post_autor=="") $post_autor=$USER['nick'];
eval ("\$user_info= \"".getTemplate("forum/newpost_guest")."\";");
eval ("\$option_notify= \"".getTemplate("forum/newpost_option_notify_form")."\";");
}
unset($sign_format);
if ($config['forum_ubb']==1) {
if ($_POST['post_bbcode']==1 || $ACTION=='view') $bbcode='checked';
/**************************************** HIDDEN_HACK Anfang ****************************************/
if($config['hidden_form_aktiv']==1 AND ($config['hidden_hidden_aktiv']==1 || $config['hidden_post_aktiv']==1 || $config['hidden_status_aktiv']==1 || $config['hidden_post_aktiv']==1 || $config['hidden_counter_aktiv']==1 || $config['hidden_field_aktiv']==1 || $config['hidden_id_aktiv']==1 || $config['hidden_pw_aktiv']==1 || $config['hidden_buddie_aktiv']==1)){
$hiddenprofilefeld=$DB->fetch_array($DB->query("SELECT `profilefields_name` FROM `".$db_tab['profilefields']."` WHERE `profilefields_id`='".intval($config['hidden_profilfelds'])."' LIMIT 1"));
$unhidden_profilfeld=$hiddenprofilefeld['profilefields_name'];
eval ("\$hidden_kopf= \"".templateinclude("hidden_hack/hidden_kopf")."\";");
eval ("\$hidden_fuss= \"".templateinclude("hidden_hack/hidden_fuss")."\";");
$counter_hidden_forum=0;
if($config['hidden_hidden_aktiv']==1){
eval ("\$hidden_button.= \"".templateinclude("hidden_hack/hidden_text")."\";"); $counter_hidden_forum++;}
if($config['hidden_status_aktiv']==1){
eval ("\$hidden_button.= \"".templateinclude("hidden_hack/hidden_status")."\";"); $counter_hidden_forum++;}
if($config['hidden_post_aktiv']==1){
eval ("\$hidden_button.= \"".templateinclude("hidden_hack/hidden_post")."\";"); $counter_hidden_forum++;}
if($config['hidden_counter_aktiv']==1){
eval ("\$hidden_button.= \"".templateinclude("hidden_hack/hidden_counter")."\";"); $counter_hidden_forum++;}
if($config['hidden_field_aktiv']==1){
eval ("\$hidden_button.= \"".templateinclude("hidden_hack/hidden_field")."\";"); $counter_hidden_forum++;}
if($config['hidden_id_aktiv']==1){
eval ("\$hidden_button.= \"".templateinclude("hidden_hack/hidden_id")."\";"); $counter_hidden_forum++;}
if($config['hidden_pw_aktiv']==1){
if($counter_hidden_forum==6) eval ("\$hidden_button.= \"".templateinclude("hidden_hack/hidden_kopf_2")."\";");
eval ("\$hidden_button.= \"".templateinclude("hidden_hack/hidden_pw")."\";"); $counter_hidden_forum++;}
if($config['hidden_buddie_aktiv']==1){
if($counter_hidden_forum==6) eval ("\$hidden_button.= \"".templateinclude("hidden_hack/hidden_kopf_2")."\";");
eval ("\$hidden_button.= \"".templateinclude("hidden_hack/hidden_buddie")."\";");}}
/**************************************** HIDDEN_HACK Ende ****************************************/
eval ("\$sign_format= \"".getTemplate("format_text")."\";");
eval ("\$option_bbcode= \"".getTemplate("forum/newpost_option_bbcode")."\";");
}
if ($config['forum_smilies']==1) {
$smilies=new smilies();
$sign_format.=$smilies->getSmilies(1);
if ($_POST['post_smilies']==1 || $ACTION=='view') $smilies='checked';
eval ("\$option_smilies= \"".getTemplate("forum/newpost_option_smilies")."\";");
}
if ($sign_format) eval ("\$sign_format= \"".getTemplate("format_table")."\";");
if ($forumcat['forumcat_voteoption']!="0" && getrights($forumcat['forumcat_voteoption']) && !$threadid>0) {
if ($_POST['post_vote']==1) $vote='checked';
eval ("\$option_vote= \"".getTemplate("forum/newpost_option_vote")."\";");
}
// if ($forumcat['forumcat_attachments']==1) eval ("\$post_attachment= \"".getTemplate("forum/newpost_attachment")."\";");
eval ("\$theme_icon= \"".getTemplate("forum/newpost_noicon")."\";");
# KNS V2 | Idee: Onkel Hotte | Umsetzung: Headless (kitnetwork.de)
if (!getrights('user')) eval ("\$show_captcha= \"".getTemplate("forum/newpost_captcha")."\";");
# EOS
$dir='images/icons';
$width=2;
$a=opendir($dir);
while ($datei=readdir($a)) {
if (strstr($datei,".gif")) {
if ($width == 10) {$theme_icon.="</tr><tr>"; $width=1;}
if ($_POST['post_icon']==$datei) $iconoption=" checked";
eval ("\$theme_icon.= \"".getTemplate("forum/newpost_icons")."\";");
$width++;
unset($iconoption);
}
}
$cs=10-$width;
if ($cs>0) $theme_icon.='<td colspan="'.$cs.'"> </td>';
closedir($a);
if ($_POST['post_uid']=='') {srand((double) microtime()*1000000); $post_uid=md5(uniqid(rand()));}
else {
$post_uid=$_POST['post_uid'];
$post_title=htmlentities($_POST['post_title']);
$post_text=htmlentities($_POST['content']);
if ($_POST['post_notify']==1) {
$notify='checked';
}
}
if(($ACTION == "addvote" || ($ACTION == $_POST['preview'] && $_POST['post_vote']==1)) && $catid && !$threadid)
{
$o = 0;
unset($vote_options);
if (is_array($vote_option)) {
foreach ($vote_option as $vote_option_single) {
if($vote_option_single != "") {
$o++;
eval ("\$vote_options .= \"".getTemplate("forum/newpost_vote_options")."\";");
}
}
}
if($_POST['vote_option_new'] != "") {
$vote_option_single = $_POST['vote_option_new'];
$o++;
eval ("\$vote_options .= \"".getTemplate("forum/newpost_vote_options")."\";");
}
eval ("\$vote_options .= \"".getTemplate("forum/newpost_vote_newoption")."\";");
if($_POST['vote_rights']=="" || !isset($_POST['vote_rights'])) $_POST['vote_rights']="user";
if ($_POST['vote_rights']=="guest") $vote_rights0="selected";
elseif ($_POST['vote_rights']=="user") $vote_rights1="selected";
elseif ($_POST['vote_rights']=="member") $vote_rights2="selected";
elseif ($_POST['vote_rights']=="mod") $vote_rights3="selected";
else $vote_rights4=" selected";
if(getrights("user")) {
$vote_option_rights = "<font class=\"small\"> Zum Abstimmen benötigter Status:</font> ";
$vote_option_rights .= "<select name=\"vote_rights\" size=\"1\" style=\"width: 170px\">\n";
$vote_option_rights .= "<option value=\"guest\" $vote_rights0>Gäste</option>\n";
$vote_option_rights .= "<option value=\"user\" $vote_rights1>User</option>\n";
if(getrights("member")) $vote_option_rights .= "<option value=\"member\" $vote_rights2>Mitglieder</option>\n";
if(getrights("mod")) $vote_option_rights .= "<option value=\"mod\" $vote_rights3>Moderatoren</option>\n";
if(getrights("admin")) $vote_option_rights .= "<option value=\"admin\" $vote_rights4>Administratoren</option>\n";
$vote_option_rights .= "</select>\n";
if($_POST['post_vote_showtoall']=="1") $vote_showtoall = "checked";
//elseif(!isset($_POST['post_vote_showtoall']) && !isset($_POST['vote_option']) && !isset($_POST['vote_option_new'])) $vote_showtoall = "checked";
$vote_option_showtoall = "<br><input class=\"checkbox\" type=\"checkbox\" name=\"post_vote_showtoall\" value=\"1\" $vote_showtoall /> <font class=\"small\">Umfrage immer anzeigen (auch bei fehlender Abstimmberechtigung)</font><br />";
}
else $vote_option_rights = "<input type=\"hidden\" name=\"vote_rights\" value=\"guest\">";
if($_POST['post_vote_multiple']==1) $vote_multiple = "checked";
if($_POST['post_vote_hideresult']) $vote_hideresult = "checked";
eval ("\$post_addvote = \"".getTemplate("forum/newpost_vote")."\";");
unset($o);
}
eval ("\$site_body.= \"".getTemplate("forum/newpost")."\";");
if ($config['forum_viewreply']>0 && $threadid>0) {
unset($reply_row);
$getreplys=$DB->query("SELECT * FROM ".$db_tab['forumpost']." WHERE forumpost_threadid='".$threadid."' ORDER by forumpost_time DESC LIMIT ".$config['forum_viewreply']);
while ($replypost=$DB->fetch_array($getreplys)) {
$row=rowcolor($row);
$replypost_text=$PARSE->parse($replypost['forumpost_text'],0,$replypost['forumpost_bbcode'],$replypost['forumpost_smilies'], $config['forum_images'],1,$config['hidden_form_aktiv']);
$replypost_time=formattime($replypost['forumpost_time']);
$replypost_autor=htmlentities($replypost['forumpost_autor']);
eval ("\$reply_row.= \"".getTemplate("forum/newpost_viewreplys_row")."\";");
}
if ($reply_row) eval ("\$site_body.= \"".getTemplate("forum/newpost_viewreplys")."\";");
}
}
}
else {$event=1; include("admin/config/event.php");}
include("forum/fuss.php");
?>
|
Dieser Beitrag wurde bereits 1 mal editiert, zuletzt von »mccracker« (17. Juli 2011, 04:46)
Ich würde noch ein paar Tage warten da hier ja noch einige unterwegs sind die sich mit den alten Versionen beschäftigen. Wenn sich dann halt keiner dazu äussern sollte würde ich bei jemanden anfragen der die alten versionen auch noch supported
Seit 02.07.2010 Papa einer süssen Tocher !!!!
http://www.burnerfm.de
Mit den besten Hits der 80´s, 90´s und von heute. Plus einigen PHPKit Addons... uvm.
Mit den besten Hits der 80´s, 90´s und von heute. Plus einigen PHPKit Addons... uvm.
OK, dann warte ich noch ein paar Tage. Ist nur leider bisschen blöde, da wir eine Chefredaktions-Kat haben, diese aber nicht befüllen können, da eben alle in der Redaktion dann die Emailbenachrichtigung bekommen. Daher ist mir dieses Anliegen schon sehr wichtig.
Aber warten wir mal ab was kommt
gruß
Aber warten wir mal ab was kommt

gruß
MC Poste es woanders.. ich find die Zeit nicht dazu und andere wollen oder können es nicht 
ich denke du hast lange genug gewartet.. schwer wirds nicht sein, solange man die zeit hat alles zusammenzufassen
sollte es bis zum WE immernoch so sein kann ich versuchen zeit zu finden.. aber leider nur am WE und das nichtmal 100%ig

ich denke du hast lange genug gewartet.. schwer wirds nicht sein, solange man die zeit hat alles zusammenzufassen

sollte es bis zum WE immernoch so sein kann ich versuchen zeit zu finden.. aber leider nur am WE und das nichtmal 100%ig
|
Achtung: Dirk Kántor ist unterwegs! Er verteilt gerne Verwarnungen ohne vorher darüber diskutiert zu haben. |
Also ich hab es mir jetzt aml angeschaut. Und bemerkt das die CatID ja auch nur über die Browser Zeile verfügbar ist wenn man ein neues Thema in der jeweiligen Kategorie verfasst.
Du kannst dann mal folgendes probieren. IST ABER UNGETESTET !!!
suche:
ersetze:
suche:
ersetze:
Du kannst dann mal folgendes probieren. IST ABER UNGETESTET !!!
suche:
|
|
PHP-Quelltext |
1 |
$forumthread=$DB->fetch_array($DB->query("SELECT forumthread_title FROM ".$db_tab['forumthread']." WHERE forumthread_id='".$threadid."' LIMIT 1"));
|
ersetze:
|
|
PHP-Quelltext |
1 |
$forumthread=$DB->fetch_array($DB->query("SELECT * FROM ".$db_tab['forumthread']." WHERE forumthread_id='".$threadid."' LIMIT 1"));
|
suche:
|
|
PHP-Quelltext |
1 2 3 4 5 6 7 8 9 |
if (is_array($mailhash)) {
$mail_title=$config['site_urls'].' - '.$lang['new_post'].': '.$forumthread['forumthread_title'];
eval ("\$mail_text= \"".getTemplate("forum/newpost_mail_text")."\";");
if($catid != '203') {
foreach ($mailhash as $email) {
mailsender($email,$mail_title,$mail_text);
}
}
}
|
ersetze:
|
|
PHP-Quelltext |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 |
define('NOEMAILID',203);
if(intval($_GET['catid']) != NOEMAILID || intval($forumthread['forumcat_id']) != NOEMAILID)
{
if(is_array($mailhash))
{
$mail_title=$config['site_urls'].' - '.$lang['new_post'].': '.$forumthread['forumthread_title'];
eval ("\$mail_text= \"".getTemplate("forum/newpost_mail_text")."\";");
foreach ($mailhash as $email)
{
mailsender($email,$mail_title,$mail_text);
}
}
}
/* Dein Code auskommentiert Anfang
if (is_array($mailhash)) {
$mail_title=$config['site_urls'].' - '.$lang['new_post'].': '.$forumthread['forumthread_title'];
eval ("\$mail_text= \"".getTemplate("forum/newpost_mail_text")."\";");
if($catid != '203') {
foreach ($mailhash as $email) {
mailsender($email,$mail_title,$mail_text);
}
}
}
Dein Code auskommentiert Ende */
|
Seit 02.07.2010 Papa einer süssen Tocher !!!!
http://www.burnerfm.de
Mit den besten Hits der 80´s, 90´s und von heute. Plus einigen PHPKit Addons... uvm.
Mit den besten Hits der 80´s, 90´s und von heute. Plus einigen PHPKit Addons... uvm.
Hi. Mensch, habe wieder keine Infomail über eine Antwort bekommen. Sorry also für meine späte Antwort.
@Devil: In welcher Datei soll ich da suchen? Newpost? Soll ja aber auch bei Antworten gelten.
gruß und danke schon mal für deine Mühe
EDIT: habe das mal eben in der newpost.php getestet und funktioniert leider nicht. Ich bekomme sowohl bei Neuem Thread als auch der Antwort eine Email an unseren Forumverteiler.
meine aktuelle newpost.php:
Hier klicken für weitere Informationen
@Devil: In welcher Datei soll ich da suchen? Newpost? Soll ja aber auch bei Antworten gelten.
gruß und danke schon mal für deine Mühe
EDIT: habe das mal eben in der newpost.php getestet und funktioniert leider nicht. Ich bekomme sowohl bei Neuem Thread als auch der Antwort eine Email an unseren Forumverteiler.
meine aktuelle newpost.php:
|
|
PHP-Quelltext |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 |
<?php
include("forum/kopf.php");
unset($cat_option);
if ($config['forum_doublepost']!=1 && $threadid>0 && $USER['id']>0) $doublepostinfo=$DB->fetch_array($DB->query("SELECT forumpost_id, forumpost_autorid FROM ".$db_tab['forumpost']." WHERE forumpost_threadid='".$threadid."' ORDER by forumpost_time DESC LIMIT 1"));
if ($threadid==0 && $catid==0) {
if (is_array($forumcat_cache)) {
foreach ($forumcat_cache_byname as $selectcat) {
if ((userrights($selectcat['forumcat_mods'])=="true" || userrights($selectcat['forumcat_user'])=="true" || getrights($selectcat['forumcat_trights'])=="true") && $selectcat['forumcat_status']==1 && $selectcat['forumcat_threads_option']==1) $cat_option.='<option value="'.$selectcat['forumcat_id'].'">'.$selectcat['forumcat_name'].'</option>';
}
if ($cat_option) eval ("\$cat_option= \"".getTemplate("forum/newpost_cat_option")."\";");
}
}
if ($catid>0 && ($forumcat['forumcat_threads_option']!=1 || $forumcat['forumcat_status']!=1)) {$event=37; include("admin/config/event.php");}
elseif (($catid==0 || !$catid) && ($threadid==0 || !$threadid) && !$cat_option) {$event=1; include("admin/config/event.php");}
elseif ($threadid!=0 && $config['forum_doublepost']!=1 && $user_id==$doublepostinfo[forumpost_autorid] && $user_id!=0) {$event=38; include("admin/config/event.php");}
elseif ($threadid!=0 && ($forumthread['forumthread_status']==0 or $forumthread[forumthread_status]==3)) {$event=36; include("admin/config/event.php");}
elseif (($catid!=0 && (userrights($forumcat['forumcat_mods'])=="true" || userrights($forumcat['forumcat_user'])=="true" || getrights($forumcat['forumcat_trights'])=="true")) || ($catid==0 && $threadid==0 && $cat_option!='') || ($threadid!=0 && (getrights($forumcat[forumcat_wrights])=="true" || userrights($forumcat['forumcat_mods'])=="true" || userrights($forumcat['forumcat_user'])=="true"))) {
if (isset($_POST['action'])) $ACTION=$_POST['action'];
else $ACTION='view';
if ($ACTION==$_POST['save'] || $ACTION==$_POST['preview']) {
if (trim($_POST['content'])!='') $post_text=$_POST['content'];
else unset($ACTION);
if (!$_POST['threadid'] && trim($_POST['post_title'])!='') $post_title=$_POST['post_title'];
elseif (!$_POST['threadid']) unset($ACTION);
if ($USER['id']>0) $post_autor=replacehtmlentities($USER['nick']);
elseif ($USER['id']==0 && trim($_POST['post_autor'])!='' && checkusername($_POST['post_autor'],1)) $post_autor=$_POST['post_autor'];
elseif ($USER['id']==0) {
$post_autor=$_POST['post_autor'];
unset($ACTION);
}
# KNS V2 | Idee: Onkel Hotte | Umsetzung: Headless (kitnetwork.de)
if(!$CAPTCHA->validCode($_POST['inputchars']) && $ACTION!=$_POST['preview'] && !getrights('user')) unset($ACTION);
# EOS
}
// Anfang Erweiterung Email mit IP u.a von arras //
$post_xxip=$thisUSER['ipaddr'];
$post_xxbrowser=$thisUSER['browser'];
$post_xxhost=gethostbyaddr($_SERVER['REMOTE_ADDR']);
$post_xxbz='Neuer Forenbeitrag';
// Ende Erweiterung Email mit IP u. a von arras//
if($_POST['vote_option']) $vote_option = $_POST['vote_option'];
unset($delvoteoption);
if($_POST['post_vote'] && is_array($vote_option))
{
foreach ($vote_option as $vote_option_single) {
if($vote_option_single == "") $delvoteoption = "1";
}
}
if($_POST['post_vote']==1 && ($forumcat['forumcat_voteoption']=="0" || !getrights($forumcat['forumcat_voteoption']))) unset($_POST['post_vote']);
if($_POST['post_vote']==1 && ($ACTION != $_POST['preview'] && (!is_array($vote_option) || count($vote_option) < 2)) || $_POST['vote_option_new'] != "" || $delvoteoption) $ACTION = "addvote";
if ($ACTION==$_POST['save'] && (isset($_POST['threadid']) || isset($_POST['catid']))) {
$check_time=time()-1800;
$DB->query("UPDATE ".$db_tab['forumpost']." SET forumpost_uid='' WHERE forumpost_time<'".$check_time."'");
$postuid=$DB->fetch_array($DB->query("SELECT COUNT(*) FROM ".$db_tab['forumpost']." WHERE forumpost_uid='".$_POST['post_uid']."' AND forumpost_time>'".$check_time."' LIMIT 1"));
if ($postuid[0]==0) {
unset($update_threadcount);
if ($threadid>0) $DB->query("UPDATE ".$db_tab['forumthread']." SET forumthread_replycount=forumthread_replycount+1, forumthread_lastreply_autor='".$_POST['post_autor']."',forumthread_lastreply_time='".time()."',forumthread_lastreply_autorid='".$USER['id']."' WHERE forumthread_id='".$threadid."'");
else {
if($_POST['post_vote']==1) { $votestatus = "1"; } else $votestatus = "0";
$DB->query("INSERT INTO ".$db_tab['forumthread']." (forumthread_autor,forumthread_autorid,forumthread_catid,forumthread_icon,forumthread_title,forumthread_lastreply_time,forumthread_lastreply_autor,forumthread_lastreply_autorid,forumthread_votetitle,forumthread_votestatus,forumthread_voterights,forumthread_votemultiple,forumthread_votehideresult,forumthread_voteshowtoall) VALUES ('".$_POST['post_autor']."','".$USER['id']."','".$catid."','".$_POST['post_icon']."','".addslashes($_POST['post_title'])."','".time()."','".$_POST['post_autor']."','".$USER['id']."','".addslashes($_POST['post_vote_title'])."','".$votestatus."','".$_POST['vote_rights']."','".$_POST['post_vote_multiple']."','".$_POST['post_vote_hideresult']."','".$_POST['post_vote_showtoall']."')");
$threadid=$DB->insert_id();
$update_threadcount=", forumcat_threadcount=forumcat_threadcount+1";
//Emailerweiterung von arras//
$post_xxbz='Neues Thema'; //Emailerweiterung von arras//
//Emailerweiterung von arras//
}
if (is_array($vote_option)) {
if (is_array($vote_option) && $post_vote_title=="") $post_vote_title=$post_title;
foreach ($vote_option as $vote_option_single) {
if ($vote_option_single!="") $DB->query("INSERT INTO ".$db_tab['forumvote']." (forumvote_threadid,forumvote_answer) VALUES ('".$threadid."','".addslashes($vote_option_single)."')");
}
}
$sqlcommand="forumcat_id='".$catid."'";
$id=$forumcat_cache[$catid]['forumcat_subcat'];
if ($id>0) {
while($id>0) {
$sqlcommand.=" OR forumcat_id='".$id."'";
$id=$forumcat_cache[$id]['forumcat_subcat'];
}
}
$DB->query("UPDATE ".$db_tab['forumcat']." SET forumcat_postcount=forumcat_postcount+1 ".$update_threadcount.",forumcat_lastreply_time='".time()."',forumcat_lastreply_threadid='".$threadid."',forumcat_lastreply_autor='".$_POST['post_autor']."',forumcat_lastreply_autorid='".$USER['id']."' WHERE ".$sqlcommand);
$DB->query("INSERT INTO ".$db_tab['forumpost']." (forumpost_threadid, forumpost_autor, forumpost_autorid, forumpost_icon, forumpost_title, forumpost_text, forumpost_time, forumpost_bbcode, forumpost_smilies, forumpost_uid, forumpost_ipaddr, forumpost_reply) VALUES ('".$threadid."','".$_POST['post_autor']."','".$USER['id']."','".$_POST['post_icon']."','".addslashes($_POST['post_title'])."','".addslashes($_POST['content'])."','".time()."','".$_POST['post_bbcode']."','".$_POST['post_smilies']."','".$_POST['post_uid']."','".$thisUSER['ipaddr']."','".$_POST['replyto']."')");
$postid=$DB->insert_id();
if ($USER['id']>0) {
$userposts=$DB->fetch_array($DB->query("SELECT COUNT(*) FROM ".$db_tab['forumpost']." WHERE forumpost_autorid='".$USER['id']."'"));
$DB->query("UPDATE ".$db_tab['user']." SET user_posts='".$userposts[0]."' WHERE user_id='".$USER['id']."'");
if ($config['ps_fa']==1) {
$DB->query("UPDATE ".$db_tab['user']." SET user_points=user_points+'".$config['ps_fn']."' WHERE user_id='".$USER['id']."'");
}
}
}
if ($USER['id']>0) $exception=" AND forumnotify_userid!='".$USER['id']."'";
else unset($exception);
unset($mailhash);
unset($sqlcommand);
$getnotify=$DB->query("SELECT forumnotify_email, forumnotify_userid FROM ".$db_tab['forumnotify']." WHERE forumnotify_threadid='".$threadid."' ".$exception);
while ($notify=$DB->fetch_array($getnotify)) {
if ($notify['forumnotify_userid']>0) {
if ($sqlcommand) $sqlcommand.=" OR user_id='".$notify['forumnotify_userid']."'";
else $sqlcommand="SELECT user_email FROM ".$db_tab['user']." WHERE user_id='".$notify['forumnotify_userid']."'";
}
else $mailhash[$notify['forumnotify_email']]=$notify['forumnotify_email'];
}
if ($sqlcommand) {
$getmails=$DB->query($sqlcommand);
while ($userinfo=$DB->fetch_array($getmails)) {
$mailhash[$userinfo['user_email']]=$userinfo['user_email'];
}
}
$forumthread=$DB->fetch_array($DB->query("SELECT forumthread_title FROM ".$db_tab['forumthread']." WHERE forumthread_id='".$threadid."' LIMIT 1"));
$mail_title=$config['site_urls'].' - '.$post_xxbz.': '.$forumthread['forumthread_title'].' Forum: '.$catid.'-';
eval ("\$mail_text= \"".getTemplate("forum/newpost_mail_notify_1")."\";"); // _1 = Emailerweiterung mit IP von arras//
notifymail('forum',$mail_title,$mail_text);
$im_title=$lang['new_post'].' '.$_POST['post_title'];
eval ("\$im_text= \"".getTemplate("forum/newpost_im_notify")."\";");
notifyim('forum',$im_title,$im_text);
if (is_array($mailhash)) {
$mail_title=$config['site_urls'].' - '.$lang['new_post'].': '.$forumthread['forumthread_title'];
eval ("\$mail_text= \"".getTemplate("forum/newpost_mail_text")."\";");
foreach ($mailhash as $email) {
mailsender($email,$mail_title,$mail_text);
}
}
if ($_POST['post_notify']==1 && $threadid>0) {
if ($USER['id']>0) $post_email=$USER['email'];
else $post_email=$_POST['post_email'];
if (emailcheck($post_email)) $DB->query("INSERT INTO ".$db_tab['forumnotify']." (forumnotify_userid,forumnotify_email,forumnotify_threadid) VALUES ('".$USER['id']."','".$post_email."','".$threadid."')");
}
header("location: include.php?path=forum/showthread.php&threadid=".$threadid."&postid=".$postid."&PHPKITSID=".session_id()."#post".$postid); exit();
}
else {
if ($ACTION==$_POST['preview']) {
$row='odd';
if ($_POST['post_icon']!='') {
$post_icon="icons/".$_POST['post_icon'];
eval ("\$post_icon= \"".getTemplate("forum/showthread_row_posticon")."\";");
}
$post_time=formattime();
$post_autor=htmlentities($post_autor);
$post_title=htmlentities(stripslashes($post_title));
# html 4 admins
// alt -> $post_text=$PARSE->parse($_POST['content'],0,$_POST['post_bbcode'],$_POST['post_smilies'],$config['forum_images'],1);
$post_text=$PARSE->parse($_POST['content'],(($PARSE->getHTMLPermission('admin', $_POST['content'])) ? 1 : 0),$_POST['post_bbcode'],$_POST['post_smilies'],$config['forum_images'],1,$config['hidden_form_aktiv']);
# / html 4 admins
eval ("\$preview_row= \"".getTemplate("forum/showthread_row")."\";");
eval ("\$site_body.= \"".getTemplate("forum/newpost_preview")."\";");
}
elseif ($ACTION!='view') {
unset($error_message);
if ($post_text=='') eval ("\$error_message.= \"".getTemplate("forum/newpost_error_text")."\";");
if (!$threadid && $post_title=="") eval ("\$error_message.= \"".getTemplate("forum/newpost_error_title")."\";");
if ($post_autor=='') eval ("\$error_message= \"".getTemplate("forum/newpost_error_autor")."\";");
# KNS V2 | Idee: Onkel Hotte | Umsetzung: Headless (kitnetwork.de)
if(!$CAPTCHA->validCode($_POST['inputchars']) && !getrights('user')) eval ("\$error_message.= \"".getTemplate("forum/newpost_error_captcha")."\";");
# EOS
elseif (!checkusername($_POST['post_autor'],1)) eval ("\$error_message= \"".getTemplate("forum/newpost_error_name")."\";");
if($ACTION == "addvote" && isset($_POST['post_vote_title']) && trim($_POST['post_vote_title'])=="") $error_message .= "• Umfrage: Bitte geben Sie die Frage an.<br />";
if($ACTION == "addvote" && (isset($option_vote) OR isset($_POST['vote_option_new'])) && ((count($vote_option) < 1 && $_POST['vote_option_new']!="") || (count($vote_option) < 2 && $_POST['vote_option_new']==""))) $error_message .= "• Umfrage: Sie müssen mindestens 2 Antwortmöglichkeiten angeben.<br />";
if ($error_message) eval ("\$post_error= \"".getTemplate("forum/newpost_error")."\";");
}
if (intval($_REQUEST['quote'])>0) {
if ($forumpost=$DB->fetch_array($DB->query("SELECT forumpost_text, forumpost_title, forumpost_autor FROM ".$db_tab['forumpost']." WHERE forumpost_id='".$_REQUEST['quote']."' AND forumpost_threadid='".$threadid."' LIMIT 1"))) {
$replyto=$_REQUEST['replyto'];
$post_title='RE: '.htmlentities($forumpost['forumpost_title']);
$post_text='[quote][i]'.$lang['original_written_by'].' '.$forumpost['forumpost_autor']."[/i]\n\n".htmlentities(stripslashes($forumpost['forumpost_text'])).'[/quote]';
/**************************************** HIDDEN_HACK Anfang ****************************************/
require_once('admin/lib/hidden.php');
$PARSEQUOTE=new PARSEQUOTE();
$post_text=$PARSEQUOTE->parsequote($post_text);
/**************************************** HIDDEN_HACK Ende ****************************************/
}
}
elseif (isset($_POST['replyto'])) $replyto=$_POST['replyto'];
else {
if ($forumpost=$DB->fetch_array($DB->query("SELECT forumpost_title FROM ".$db_tab['forumpost']." WHERE forumpost_threadid='".$threadid."' LIMIT 1"))) {
$post_title='re: '.htmlentities(eregi_replace('^re: *','',$forumpost['forumpost_title']));
}
}
if ($USER['id']>0) {
eval ("\$user_info= \"".getTemplate("forum/newpost_user")."\";");
}
else {
if ($post_autor=="") $post_autor=$USER['nick'];
eval ("\$user_info= \"".getTemplate("forum/newpost_guest")."\";");
eval ("\$option_notify= \"".getTemplate("forum/newpost_option_notify_form")."\";");
}
unset($sign_format);
if ($config['forum_ubb']==1) {
if ($_POST['post_bbcode']==1 || $ACTION=='view') $bbcode='checked';
/**************************************** HIDDEN_HACK Anfang ****************************************/
if($config['hidden_form_aktiv']==1 AND ($config['hidden_hidden_aktiv']==1 || $config['hidden_post_aktiv']==1 || $config['hidden_status_aktiv']==1 || $config['hidden_post_aktiv']==1 || $config['hidden_counter_aktiv']==1 || $config['hidden_field_aktiv']==1 || $config['hidden_id_aktiv']==1 || $config['hidden_pw_aktiv']==1 || $config['hidden_buddie_aktiv']==1)){
$hiddenprofilefeld=$DB->fetch_array($DB->query("SELECT `profilefields_name` FROM `".$db_tab['profilefields']."` WHERE `profilefields_id`='".intval($config['hidden_profilfelds'])."' LIMIT 1"));
$unhidden_profilfeld=$hiddenprofilefeld['profilefields_name'];
eval ("\$hidden_kopf= \"".templateinclude("hidden_hack/hidden_kopf")."\";");
eval ("\$hidden_fuss= \"".templateinclude("hidden_hack/hidden_fuss")."\";");
$counter_hidden_forum=0;
if($config['hidden_hidden_aktiv']==1){
eval ("\$hidden_button.= \"".templateinclude("hidden_hack/hidden_text")."\";"); $counter_hidden_forum++;}
if($config['hidden_status_aktiv']==1){
eval ("\$hidden_button.= \"".templateinclude("hidden_hack/hidden_status")."\";"); $counter_hidden_forum++;}
if($config['hidden_post_aktiv']==1){
eval ("\$hidden_button.= \"".templateinclude("hidden_hack/hidden_post")."\";"); $counter_hidden_forum++;}
if($config['hidden_counter_aktiv']==1){
eval ("\$hidden_button.= \"".templateinclude("hidden_hack/hidden_counter")."\";"); $counter_hidden_forum++;}
if($config['hidden_field_aktiv']==1){
eval ("\$hidden_button.= \"".templateinclude("hidden_hack/hidden_field")."\";"); $counter_hidden_forum++;}
if($config['hidden_id_aktiv']==1){
eval ("\$hidden_button.= \"".templateinclude("hidden_hack/hidden_id")."\";"); $counter_hidden_forum++;}
if($config['hidden_pw_aktiv']==1){
if($counter_hidden_forum==6) eval ("\$hidden_button.= \"".templateinclude("hidden_hack/hidden_kopf_2")."\";");
eval ("\$hidden_button.= \"".templateinclude("hidden_hack/hidden_pw")."\";"); $counter_hidden_forum++;}
if($config['hidden_buddie_aktiv']==1){
if($counter_hidden_forum==6) eval ("\$hidden_button.= \"".templateinclude("hidden_hack/hidden_kopf_2")."\";");
eval ("\$hidden_button.= \"".templateinclude("hidden_hack/hidden_buddie")."\";");}}
/**************************************** HIDDEN_HACK Ende ****************************************/
eval ("\$sign_format= \"".getTemplate("format_text")."\";");
eval ("\$option_bbcode= \"".getTemplate("forum/newpost_option_bbcode")."\";");
}
if ($config['forum_smilies']==1) {
$smilies=new smilies();
$sign_format.=$smilies->getSmilies(1);
if ($_POST['post_smilies']==1 || $ACTION=='view') $smilies='checked';
eval ("\$option_smilies= \"".getTemplate("forum/newpost_option_smilies")."\";");
}
if ($sign_format) eval ("\$sign_format= \"".getTemplate("format_table")."\";");
if ($forumcat['forumcat_voteoption']!="0" && getrights($forumcat['forumcat_voteoption']) && !$threadid>0) {
if ($_POST['post_vote']==1) $vote='checked';
eval ("\$option_vote= \"".getTemplate("forum/newpost_option_vote")."\";");
}
// if ($forumcat['forumcat_attachments']==1) eval ("\$post_attachment= \"".getTemplate("forum/newpost_attachment")."\";");
eval ("\$theme_icon= \"".getTemplate("forum/newpost_noicon")."\";");
# KNS V2 | Idee: Onkel Hotte | Umsetzung: Headless (kitnetwork.de)
if (!getrights('user')) eval ("\$show_captcha= \"".getTemplate("forum/newpost_captcha")."\";");
# EOS
$dir='images/icons';
$width=2;
$a=opendir($dir);
while ($datei=readdir($a)) {
if (strstr($datei,".gif")) {
if ($width == 10) {$theme_icon.="</tr><tr>"; $width=1;}
if ($_POST['post_icon']==$datei) $iconoption=" checked";
eval ("\$theme_icon.= \"".getTemplate("forum/newpost_icons")."\";");
$width++;
unset($iconoption);
}
}
$cs=10-$width;
if ($cs>0) $theme_icon.='<td colspan="'.$cs.'"> </td>';
closedir($a);
if ($_POST['post_uid']=='') {srand((double) microtime()*1000000); $post_uid=md5(uniqid(rand()));}
else {
$post_uid=$_POST['post_uid'];
$post_title=htmlentities($_POST['post_title']);
$post_text=htmlentities($_POST['content']);
if ($_POST['post_notify']==1) {
$notify='checked';
}
}
if(($ACTION == "addvote" || ($ACTION == $_POST['preview'] && $_POST['post_vote']==1)) && $catid && !$threadid)
{
$o = 0;
unset($vote_options);
if (is_array($vote_option)) {
foreach ($vote_option as $vote_option_single) {
if($vote_option_single != "") {
$o++;
eval ("\$vote_options .= \"".getTemplate("forum/newpost_vote_options")."\";");
}
}
}
if($_POST['vote_option_new'] != "") {
$vote_option_single = $_POST['vote_option_new'];
$o++;
eval ("\$vote_options .= \"".getTemplate("forum/newpost_vote_options")."\";");
}
eval ("\$vote_options .= \"".getTemplate("forum/newpost_vote_newoption")."\";");
if($_POST['vote_rights']=="" || !isset($_POST['vote_rights'])) $_POST['vote_rights']="user";
if ($_POST['vote_rights']=="guest") $vote_rights0="selected";
elseif ($_POST['vote_rights']=="user") $vote_rights1="selected";
elseif ($_POST['vote_rights']=="member") $vote_rights2="selected";
elseif ($_POST['vote_rights']=="mod") $vote_rights3="selected";
else $vote_rights4=" selected";
if(getrights("user")) {
$vote_option_rights = "<font class=\"small\"> Zum Abstimmen benötigter Status:</font> ";
$vote_option_rights .= "<select name=\"vote_rights\" size=\"1\" style=\"width: 170px\">\n";
$vote_option_rights .= "<option value=\"guest\" $vote_rights0>Gäste</option>\n";
$vote_option_rights .= "<option value=\"user\" $vote_rights1>User</option>\n";
if(getrights("member")) $vote_option_rights .= "<option value=\"member\" $vote_rights2>Mitglieder</option>\n";
if(getrights("mod")) $vote_option_rights .= "<option value=\"mod\" $vote_rights3>Moderatoren</option>\n";
if(getrights("admin")) $vote_option_rights .= "<option value=\"admin\" $vote_rights4>Administratoren</option>\n";
$vote_option_rights .= "</select>\n";
if($_POST['post_vote_showtoall']=="1") $vote_showtoall = "checked";
//elseif(!isset($_POST['post_vote_showtoall']) && !isset($_POST['vote_option']) && !isset($_POST['vote_option_new'])) $vote_showtoall = "checked";
$vote_option_showtoall = "<br><input class=\"checkbox\" type=\"checkbox\" name=\"post_vote_showtoall\" value=\"1\" $vote_showtoall /> <font class=\"small\">Umfrage immer anzeigen (auch bei fehlender Abstimmberechtigung)</font><br />";
}
else $vote_option_rights = "<input type=\"hidden\" name=\"vote_rights\" value=\"guest\">";
if($_POST['post_vote_multiple']==1) $vote_multiple = "checked";
if($_POST['post_vote_hideresult']) $vote_hideresult = "checked";
eval ("\$post_addvote = \"".getTemplate("forum/newpost_vote")."\";");
unset($o);
}
eval ("\$site_body.= \"".getTemplate("forum/newpost")."\";");
if ($config['forum_viewreply']>0 && $threadid>0) {
unset($reply_row);
$getreplys=$DB->query("SELECT * FROM ".$db_tab['forumpost']." WHERE forumpost_threadid='".$threadid."' ORDER by forumpost_time DESC LIMIT ".$config['forum_viewreply']);
while ($replypost=$DB->fetch_array($getreplys)) {
$row=rowcolor($row);
$replypost_text=$PARSE->parse($replypost['forumpost_text'],0,$replypost['forumpost_bbcode'],$replypost['forumpost_smilies'], $config['forum_images'],1,$config['hidden_form_aktiv']);
$replypost_time=formattime($replypost['forumpost_time']);
$replypost_autor=htmlentities($replypost['forumpost_autor']);
eval ("\$reply_row.= \"".getTemplate("forum/newpost_viewreplys_row")."\";");
}
if ($reply_row) eval ("\$site_body.= \"".getTemplate("forum/newpost_viewreplys")."\";");
}
}
}
else {$event=1; include("admin/config/event.php");}
include("forum/fuss.php");
?>
|
Dieser Beitrag wurde bereits 3 mal editiert, zuletzt von »mccracker« (10. September 2011, 15:45)

- 1
- 2

Ähnliche Themen
-
alte Versionen [1.6.03|1.6.1|1.6.4] »-
1.6.1 Forumpost für User auf Zeit beschränken?
(12. Oktober 2009, 20:57)
-
alte Versionen [1.6.03|1.6.1|1.6.4] »-
BBCode markierter Text
(15. Januar 2008, 17:00)


