Point Mod 2.0.0 funzt ned auf 2.0.6

Du hast Probleme beim Einbau oder bei der Benutzung eines Mods? In diesem Forum bist du richtig.
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
punker
Mitglied
Beiträge: 305
Registriert: 28.05.2003 11:11
Wohnort: Minden

Point Mod 2.0.0 funzt ned auf 2.0.6

Beitrag von punker »

Hallo Progger Kollegen,

hat jemand ne Idea wie man den Points Mod 2.0.0 auf 2.0.6 zum funktioneren bringt... habe alles in den dateien geändert.

leider funktioniert die mod_install.php beim 2.0.6 nicht?? :-(

Bitte um hilfe!!

Danke und CU

Steff
Es grüßt
der Stefan :)
Benutzeravatar
punker
Mitglied
Beiträge: 305
Registriert: 28.05.2003 11:11
Wohnort: Minden

Beitrag von punker »

hat keiner ne idee??? :roll:

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.1 2002/06/25 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.
 *
 ***************************************************************************/

function _sql($sql, &$errored, &$error_ary, $echo_dot = true)
{
	global $db;

	if (!($result = $db->sql_query($sql)))
	{
		$errored = true;
		$error_ary['sql'][] = (is_array($sql)) ? $sql[$i] : $sql;
		$error_ary['error_code'][] = $db->sql_error();
	}

	if ($echo_dot)
	{
		echo '.';
		flush();
	}

	return $result;
}

define('IN_PHPBB', 1);
$phpbb_root_path = './';
include($phpbb_root_path . 'extension.inc');
include($phpbb_root_path . 'config.'.$phpEx);
include($phpbb_root_path . 'includes/constants.'.$phpEx);
include($phpbb_root_path . 'includes/db.'.$phpEx);

?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>Mod Installation</title>
<meta http-equiv="Content-Type" content="text/html;">
<meta http-equiv="Content-Style-Type" content="text/css">
<style type="text/css">
<!--

font,th,td,p,body { font-family: "Courier New", courier; font-size: 11pt }

a:link,a:active,a:visited { color : #006699; }
a:hover		{ text-decoration: underline; color : #DD6900;}

hr	{ height: 0px; border: solid #D1D7DC 0px; border-top-width: 1px;}

.maintitle,h1,h2	{font-weight: bold; font-size: 22px; font-family: "Trebuchet MS",Verdana, Arial, Helvetica, sans-serif; text-decoration: none; line-height : 120%; color : #000000;}

.ok	{color:green}

/* Import the fancy styles for IE only (NS4.x doesn't use the @import function) */
@import	url("templates/subSilver/formIE.css");
-->
</style>
</head>
<body bgcolor="#FFFFFF" text="#000000" link="#006699" vlink="#5584AA">

<table width="100%" border="0" cellspacing="0" cellpadding="10" align="center">
	<tr>
		<td><table width="100%" border="0" cellspacing="0" cellpadding="0">
			<tr>
				<td><img src="templates/subSilver/images/logo_phpBB.gif" border="0" alt="Forum Home" vspace="1" /></td>
				<td align="center" width="100%" valign="middle"><span class="maintitle">Mod Installation</span></td>
			</tr>
		</table></td>
	</tr>
</table>

<br	clear="all" />

<h2>Information</h2>

<?php

echo '<p>Database type &nbsp; &nbsp;:: <b>' . SQL_LAYER . '</b><br />' . "\n";

$sql = "SELECT config_value
	FROM " . CONFIG_TABLE . "
	WHERE config_name = 'version'";
if (!($result = $db->sql_query($sql)))
{
	die("Couldn't obtain version info");
}

$row = $db->sql_fetchrow($result);

$sql = array();

if ($row['config_value'] != '.0.4')
{
	echo 'This mod only works with version 2.0.4 of phpBB.<br />';
	exit();
}

echo 'phpBB version &nbsp; &nbsp;:: <b>2' . $row['config_value'] . '</b></p>' . "\n";

if (SQL_LAYER != 'mysql' && SQL_LAYER != 'mysql4')
{
	echo '<p>This mod has only been tested on MySQL and may only work on MySQL. If you are interested in this mod working for another database type contact me.</p>';
	exit();
}

switch (SQL_LAYER)
{
	case 'mysql':
	case 'mysql4':
		$sql[] = "ALTER TABLE " . FORUMS_TABLE . " ADD points_disabled TINYINT(1) NOT NULL AFTER prune_enable";
		$sql[] = "ALTER TABLE " . USERS_TABLE . " ADD user_notify_donation TINYINT(1) NOT NULL AFTER user_notify_pm";
		$sql[] = "ALTER TABLE " . USERS_TABLE . " ADD user_points INT NOT NULL";
		$sql[] = "INSERT INTO " . CONFIG_TABLE . " VALUES ('points_reply', '1')";
		$sql[] = "INSERT INTO " . CONFIG_TABLE . " VALUES ('points_topic', '2')";
		$sql[] = "INSERT INTO " . CONFIG_TABLE . " VALUES ('points_post', '1')";
		$sql[] = "INSERT INTO " . CONFIG_TABLE . " VALUES ('points_donate', '1')";
		$sql[] = "INSERT INTO " . CONFIG_TABLE . " VALUES ('points_name', 'Points')";
		$sql[] = "INSERT INTO " . CONFIG_TABLE . " VALUES ('points_user_group_auth_ids', '')";
		$sql[] = "INSERT INTO " . CONFIG_TABLE . " VALUES ('points_system_version', '2.0.0')";
	break;

	case 'postgresql':
	case 'mssql-odbc':
	case 'mssql':
	case 'msaccess':
	break;
}

echo '<h2>Updating database schema & data</h2>' . "\n";
echo '<p>Progress :: <b>';
flush();

$error_ary = array();
$errored = false;
if (count($sql))
{
	for($i = 0; $i < count($sql); $i++)
	{
		_sql($sql[$i], $errored, $error_ary);
	}

	echo '</b> <b class="ok">Done</b><br />Result &nbsp; :: ' . "\n";

	if ($errored)
	{
		echo '<b>Some queries failed, the statements and errors are listing below</b>' . "\n";
		echo '<ul>';

		for($i = 0; $i < count($error_ary['sql']); $i++)
		{
			echo '<li>Error :: <b>' . $error_ary['error_code'][$i]['message'] . '</b><br />';
			echo 'SQL &nbsp; :: <b>' . $error_ary['sql'][$i] . '</b><br /><br /></li>';
		}

		echo '</ul>' . "\n";
		echo '<p>Contact me so I can fix the errors.</p>' . "\n";
		exit();
	}
	else
	{
		echo '<b>No errors</b>' . "\n";
	}
}

echo '<h2>Install completed</h2>' . "\n";
echo 'You can now delete this file. To undo any changes run the mod_uninstall.php file.';
?>

<br	clear="all" />

</body>
</html>
Hier mal der inhalt der mod_install.php
Was müsste ich für eingeben wenn, ich manuell in DB laden möchte?
Es grüßt
der Stefan :)
Benutzeravatar
punker
Mitglied
Beiträge: 305
Registriert: 28.05.2003 11:11
Wohnort: Minden

Beitrag von punker »

keiner eine idee??? :oops: :cry:
Es grüßt
der Stefan :)
Benutzeravatar
Dark Night
Mitglied
Beiträge: 184
Registriert: 18.08.2002 03:22
Wohnort: Holzweißig
Kontaktdaten:

Beitrag von Dark Night »

die nötogen Tabellen samt inhalt manuel über phpMyAdmin eintragen *gg* so würde ich es jetzt machen mußte es schon mal so machen mit dem Nickpage mod ^^ hatte die anleitung nicht richitg gelesen und dann konnte ich die install.php oder wie da jetzt hies ausfüren kamm immer fehler das ne tabelle in der DB fehlte ^^ nur brauch ich aber diese install nicht mehr da das schon beim installen vom gesamten vorum gemacht wird *Fg*

[köpfchen muß man haben] :D
Dave
Mitglied
Beiträge: 2085
Registriert: 25.05.2003 15:03
Wohnort: Wuppertal

Beitrag von Dave »

in der Datei oben :roll: (mod_install.php)

Suche:

Code: Alles auswählen

if ($row['config_value'] != '.0.4') 
erstze mit:

Code: Alles auswählen

if ($row['config_value'] != '.0.6') 
und suche:

Code: Alles auswählen

echo 'This mod only works with version 2.0.4 of phpBB.<br />';
ersetze mit:

Code: Alles auswählen

echo 'This mod only works with version 2.0.6 of phpBB.<br />';

klappt wunderbar :D
Antworten

Zurück zu „phpBB 2.0: Mod Support“