Beiträge nicht zählen (in einem Threat!)

Du suchst einen bestimmten Mod, weißt aber nicht genau wo bzw. ob er überhaupt existiert? Wenn dir dieser Artikel nicht weiterhilft, kannst du hier den von dir gewünschten/gesuchten Mod beschreiben ...
Falls ein Mod-Autor eine der Anfragen hier aufnimmt um einen neuen Mod zu entwicklen, geht's in phpBB 2.0: Mods in Entwicklung weiter.
Forumsregeln
phpBB 2.0 hat das Ende seiner Lebenszeit überschritten
phpBB 2.0 wird nicht mehr aktiv unterstützt. Insbesondere werden - auch bei Sicherheitslücken - keine Patches mehr bereitgestellt. Der Einsatz von phpBB 2.0 erfolgt daher auf eigene Gefahr. Wir empfehlen einen Umstieg auf phpBB 3.0, welches aktiv weiterentwickelt wird und für welches regelmäßig Updates zur Verfügung gestellt werden.
Antworten
Benutzeravatar
vinci
Mitglied
Beiträge: 69
Registriert: 19.10.2004 22:40
Wohnort: Stuttgart
Kontaktdaten:

Beiträge nicht zählen (in einem Threat!)

Beitrag von vinci »

Hi,

hab schon die suche bemüht, aber leider nix gefunden.

ich möchte, dass die beiträge für ein bestimmtes thema nich gezählt werden bzw. dem user angerechnet werden.

für foren gibt es ja schon mods aber für ein bestimmtes thema leider noch nicht.

irgendjemand ne ahnung?

gruß & danke

Vinci
Benutzeravatar
ATARI
Mitglied
Beiträge: 1684
Registriert: 22.02.2004 16:51
Wohnort: Monaco Di Bavaria

Beitrag von ATARI »

stop post count mod.
gibts bei phpbbhacks.com
Man soll aufhören wenn´s am schönsten ist!

Servus phpBB! ;)
Benutzeravatar
vinci
Mitglied
Beiträge: 69
Registriert: 19.10.2004 22:40
Wohnort: Stuttgart
Kontaktdaten:

Beitrag von vinci »

ATARI hat geschrieben:stop post count mod.
gibts bei phpbbhacks.com
hmmm, finde da leider nix passendes
Benutzeravatar
ATARI
Mitglied
Beiträge: 1684
Registriert: 22.02.2004 16:51
Wohnort: Monaco Di Bavaria

Beitrag von ATARI »

Code: Alles auswählen

#################################################################
## Mod Title: Stop Posts Count From Increasing
## Mod Version: 1.0.0
## Author: ssjslim < ssjslim@yahoo.com > - http://bbmod.sourceforge.net
## Description: Stop a user's posts count from increasing when they post in a certain forum.
##
## Installation Level: easy
## Installation Time: 5 Minutes
## Files To Edit: functions_post.php, admin_board.php, board_config_body.tpl, lang_main.php
## Included Files: mod_install.php, mod_uninstall.php
#################################################################
## Security Disclaimer: This MOD Cannot Be Posted To Or Added At Any Non-Official phpBB Sites
#################################################################
##
## Author Note:
## You should change all your languages and themes if you use others
## then English and subSilver.
#################################################################
##
## Installation
##
## 1) Upload all files to their respective location in this format.
##
##		/mod_install.php (Only needed for install)
##		/mod_uninstall.php (Only needed for uninstall)
##
## 2) Run mod_install.php from your web broswer to make the table changes.
## 3) Read below to make the rest of the changes.
#################################################################
## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD
#################################################################

#
#-----[ OPEN ]------------------------------------------
#
includes/functions_post.php

#
#-----[ FIND ]------------------------------------------
#
	if ( $topic_update_sql != '' )
	{
		$sql = "UPDATE " . TOPICS_TABLE . " SET 
			$topic_update_sql 
			WHERE topic_id = $topic_id";
		if ( !($result = $db->sql_query($sql)) )
		{
			message_die(GENERAL_ERROR, 'Error in posting', '', __LINE__, __FILE__, $sql);
		}
	}

#
#-----[ AFTER, ADD ]----------------------------------
#

	$board_config['no_post_count_forum_id'] = $GLOBALS['board_config']['no_post_count_forum_id'];
	if( strstr($board_config['no_post_count_forum_id'], ',') )
	{
		$fids = explode(',', $board_config['no_post_count_forum_id']);
	
		while( list($foo, $id) = each($fids) )
		{
			$fid[] = intval( trim($id) );
		}
	}
	else
	{
		$fid[] = intval( trim($board_config['no_post_count_forum_id']) );
	}
	reset($fid);

#
#-----[ FIND ]------------------------------------------
#
	if ( $mode != 'poll_delete' )

#
#-----[ REPLACE WITH ]------------------------------------------
#
	if ( $mode != 'poll_delete' && in_array($forum_id, $fid) == false )

#
#-----[ OPEN ]------------------------------------------
#
admin/admin_board.php

#
#-----[ FIND ]------------------------------------------
#
	"L_RESET" => $lang['Reset'],

#
#-----[ AFTER, ADD ]------------------------------------------
#
	
	'NO_POST_COUNT_FORUM_ID' => $new['no_post_count_forum_id'],
	'NO_POST_COUNT' => $lang['no_post_count'],
	'NO_POST_COUNT_EXPLAIN' =>$lang['no_post_count_explain'],

#
#-----[ OPEN ]------------------------------------------
#
templates/subSilver/admin/board_config_body.tpl

#
#-----[ FIND ]------------------------------------------
#
	<tr>
		<td class="row1">{L_MAX_POLL_OPTIONS}</td>
		<td class="row2"><input type="text" name="max_poll_options" size="4" maxlength="4" value="{MAX_POLL_OPTIONS}" /></td>
	</tr>
#
#-----[ BEFORE, ADD ]------------------------------------------
#
	<tr>
		<td class="row1">{NO_POST_COUNT}<br /><span class="gensmall">{NO_POST_COUNT_EXPLAIN}</span></td>
		<td class="row2"><input type="text" name="no_post_count_forum_id" maxlength="255" value="{NO_POST_COUNT_FORUM_ID}" /></td>
	</tr>

#
#-----[ OPEN ]------------------------------------------
#
language/lang_english/lang_main.php

#
#-----[ FIND  ]------------------------------------------
#
$lang['A_critical_error'] = "A Critical Error Occurred";

#
#-----[ AFTER, ADD ]------------------------------------------
#

//No Post Count MOD
$lang['no_post_count'] = "No post count in forum";
$lang['no_post_count_explain'] = "Forum IDs of forums you don't want users post to increase. Separate multiple forum IDs with commas";

#
#-----[ SAVE/CLOSE ALL FILES ]------------------------------------------
#
# EoM

sql (speichern als php datei und ausführen)

Code: Alles auswählen

<?php
/***************************************************************************
 *                               mod_install.php
 *                            -------------------
 *   begin                : Sunday, April 14, 2002
 *   copyright            : (C) 2002 Bulletin Board Mods
 *   email                : ssjslim@yahoo.com
 *
 *   $Id: mod_install.php,v 1.0.0 2002/04/19 12:59:59 explosive Exp $
 *
 *
 ***************************************************************************/

/***************************************************************************
 *
 *   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, or
 *   (at your option) any later version.
 *
 ***************************************************************************/
 
define('IN_PHPBB', true);
$phpbb_root_path='./';
include($phpbb_root_path.'extension.inc');
include($phpbb_root_path.'common.'.$phpEx);

//
// Start session management
//
$userdata = session_pagestart($user_ip, PAGE_INDEX);
init_userprefs($userdata);
//
// End session management
//

if( !$userdata['session_logged_in'] )
{
	header('Location: ' . append_sid("login.$phpEx?redirect=mod_install.$phpEx", true));
}

if( $userdata['user_level'] != ADMIN )
{
	message_die(GENERAL_MESSAGE, $lang['Not_Authorised']);
}

if( !strstr($dbms, "mysql") )
{
    if( !isset($bypass) )
    {
        $message = 'This mod has only been tested on MySQL and may only work on MySQL.<br />';
        $message .= 'Click <a href="mod_install.php?bypass=true">here</a> to install anyways.';
        message_die(GENERAL_MESSAGE, $message);
    }
}

$sql = array();
$sql[] = "INSERT INTO " . CONFIG_TABLE . " VALUES ('no_post_count_forum_id', '')";

$sql_count = count($sql);

echo "<html>\n";
echo "<body>\n";

for($i = 0; $i < $sql_count; $i++)
{
	echo "Running :: " . $sql[$i];
	flush();

	if ( !$db->sql_query($sql[$i]) )
	{
		$errored = true;
		$error = $db->sql_error();
		echo " -> <b>FAILED</b> ---> <u>" . $error['message'] . "</u><br /><br />\n\n";
	}
	else
	{
		echo " -> <b>COMPLETED</b><br /><br />\n\n";
	}
}

if( $errored )
{
    $message = "Some of the querys have failed, contact me so I can fix the errors.";
}
else
{
    $message = "The table have been edited successfully. You can now delete this file. To undo any changes run the mod_uninstall.php file.";
}

echo "\n<br />\n<b>COMPLETE!</b><br />\n";
echo $message . "<br />\n";
echo "</body>\n";
echo "</html>\n";
exit();

?>
Man soll aufhören wenn´s am schönsten ist!

Servus phpBB! ;)
Benutzeravatar
vinci
Mitglied
Beiträge: 69
Registriert: 19.10.2004 22:40
Wohnort: Stuttgart
Kontaktdaten:

Beitrag von vinci »

ja, aber mit dem kann man keine bestimmte Threats, sondern nur Foren auswählen.

oder lieg ich da falsch?
Benutzeravatar
ATARI
Mitglied
Beiträge: 1684
Registriert: 22.02.2004 16:51
Wohnort: Monaco Di Bavaria

Beitrag von ATARI »

nen anderen gibts nicht
Man soll aufhören wenn´s am schönsten ist!

Servus phpBB! ;)
Benutzeravatar
vinci
Mitglied
Beiträge: 69
Registriert: 19.10.2004 22:40
Wohnort: Stuttgart
Kontaktdaten:

Beitrag von vinci »

ATARI hat geschrieben:nen anderen gibts nicht
kk

danke :wink:
Elmshorner
Mitglied
Beiträge: 23
Registriert: 20.01.2005 08:10

...

Beitrag von Elmshorner »

Moin,

habe mir den Mod auch eingebaut, allerdings wird bei
mir weitergezählt.
#-----[ FIND ]------------------------------------------
#
if ( $mode != 'poll_delete' )
Diese zeile gibt es zwei mal, muß ich beide ändern
oder nur die erste oder zweite ?


Gruß
Der Elmshorner
Tuxman
Mitglied
Beiträge: 2284
Registriert: 24.05.2003 13:32
Kontaktdaten:

Beitrag von Tuxman »

Nur die erste, denke ich, sonst würde es dabeistehen.
tux. Ehemaliger Moderator ohne Sondertitel.
tuxproject.de
Antworten

Zurück zu „phpBB 2.0: Mod Suche/Anfragen“