X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=inc%2Fextensions%2Fext-nickname.php;h=618d44b9f92184a1cf8706357b5d18a6e94bf864;hb=2fa9f811cf143c0fcafe197320dfb119310a6904;hp=9eeaed12e7e9ca3e979e0174e4f9730cdc291697;hpb=adb34cea9c14bcac14030f8eb1e6ae2c3231c962;p=mailer.git diff --git a/inc/extensions/ext-nickname.php b/inc/extensions/ext-nickname.php index 9eeaed12e7..618d44b9f9 100644 --- a/inc/extensions/ext-nickname.php +++ b/inc/extensions/ext-nickname.php @@ -18,6 +18,7 @@ * svn:keywords Date Revision" (autoprobset!) at least!!!!!! * * -------------------------------------------------------------------- * * Copyright (c) 2003 - 2009 by Roland Haeder * + * Copyright (c) 2009, 2010 by Mailer Developer Team * * For more information visit: http://www.mxchange.org * * * * This program is free software; you can redistribute it and/or modify * @@ -39,7 +40,7 @@ // Some security stuff... if (!defined('__SECURITY')) { die(); -} +} // END - if // Version number setThisExtensionVersion('0.1.9'); @@ -59,7 +60,7 @@ switch (getExtensionMode()) { // SQL commands to run addExtensionSql("DELETE LOW_PRIORITY FROM `{?_MYSQL_PREFIX?}_member_menu` WHERE `what`='nickname'"); addExtensionSql("DELETE LOW_PRIORITY FROM `{?_MYSQL_PREFIX?}_admin_menu` WHERE `what` IN ('config_nickname','list_nickname')"); - addExtensionSql("DROP TABLE IF EXISTS `{?_MYSQL_PREFIX?}_nickname_history`"); + addExtensionSql('DROP TABLE IF EXISTS `{?_MYSQL_PREFIX?}_nickname_history`'); break; case 'activate': // Do stuff when admin activates this extension @@ -175,16 +176,16 @@ switch (getExtensionMode()) { case '0.1.9': // SQL queries for v0.1.9 addAdminMenuSql('user','list_nickname','Nickname-Historie','Listet alle verwendeten Nicknames der Mitglieder auf.', 12); - addExtensionSql("DROP TABLE IF EXISTS `{?_MYSQL_PREFIX?}_nickname_history`"); + addExtensionSql('DROP TABLE IF EXISTS `{?_MYSQL_PREFIX?}_nickname_history`'); addExtensionSql("CREATE TABLE `{?_MYSQL_PREFIX?}_nickname_history` ( -id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, -userid BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, -nickname VARCHAR(255) NOT NULL DEFAULT '', -added TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP, -last_used TIMESTAMP NOT NULL DEFAULT '0000-00-00 00:00:00', -INDEX userid (userid), -INDEX (last_used DESC), -PRIMARY KEY (id) +`id` BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +`userid` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, +`nickname` VARCHAR(255) NOT NULL DEFAULT '', +`added` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP, +`last_used` TIMESTAMP NOT NULL DEFAULT '0000-00-00 00:00:00', +INDEX `userid` (`userid`), +INDEX (`last_used` DESC), +PRIMARY KEY (`id`) ) TYPE={?_TABLE_TYPE?} COMMENT='History of used nicknames'"); // Update notes (these will be set as task text!) @@ -203,9 +204,9 @@ PRIMARY KEY (id) break; default: // Unknown extension mode - logDebugMessage(__FILE__, __LINE__, sprintf("Unknown extension mode %s detected.", getExtensionMode())); + logDebugMessage(__FILE__, __LINE__, sprintf("Unknown extension mode %s in extension %s detected.", getExtensionMode(), getCurrentExtensionName())); break; -} +} // END - switch -// +// [EOF] ?>