inc/modules/admin/what-list_primera.php svneol=native#text/plain
inc/modules/admin/what-list_rallyes.php svneol=native#text/plain
inc/modules/admin/what-list_refs.php svneol=native#text/plain
+inc/modules/admin/what-list_server_name.php svneol=native#text/plain
inc/modules/admin/what-list_sponsor.php svneol=native#text/plain
inc/modules/admin/what-list_sponsor_pay.php svneol=native#text/plain
inc/modules/admin/what-list_sponsor_pays.php svneol=native#text/plain
templates/de/html/admin/admin_list_refs_nodata.tpl svneol=native#text/plain
templates/de/html/admin/admin_list_refs_norefs.tpl svneol=native#text/plain
templates/de/html/admin/admin_list_refs_row.tpl svneol=native#text/plain
+templates/de/html/admin/admin_list_server_name_log.tpl svneol=native#text/plain
+templates/de/html/admin/admin_list_server_name_log_row.tpl svneol=native#text/plain
templates/de/html/admin/admin_list_sponsor.tpl svneol=native#text/plain
templates/de/html/admin/admin_list_sponsor_details.tpl svneol=native#text/plain
templates/de/html/admin/admin_list_sponsor_pay.tpl svneol=native#text/plain
break;
case '0.9.1': // SQL queries for v0.9.1
+ // Add admin menu
addAdminMenuSql('misc', 'list_server_name', 'Verkehrte Domains auflisten', 'Listet alle als verkehrt erkannten Domains auf.', 4);
+
+ // Create table
addCreateTableSql('server_name_log', "
`server_name_id` BIGINT (20) NOT NULL AUTO_INCREMENT,
`server_name` VARCHAR (255) NOT NULL DEFAULT 'invalid',
-`server_name_added` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
`server_name_remote_addr` VARCHAR (15) NOT NULL DEFAULT '0.0.0.0',
`server_name_ua` TINYTEXT NULL DEFAULT NULL,
`server_name_referrer` TINYTEXT NULL DEFAULT NULL,
+`server_name_added` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
`server_name_counter` BIGINT (20) NOT NULL DEFAULT 1,
PRIMARY KEY (`server_name_id`)
", 'Logging of wrong SERVER_NAME');
// Generates an URL for the dereferer
function generateDereferrerUrl ($url) {
// Don't de-refer our own links!
- if (substr($url, 0, strlen(getUrl())) != getUrl()) {
+ if ((!empty($url)) && (substr($url, 0, strlen(getUrl())) != getUrl())) {
// Encode URL
$encodedUrl = encodeString(compileUriCode($url));
// Admin - history entries - generic
'ADMIN_HISTORY_VALUE' => "Historie-Eintrag",
- 'ADMIN_HISTORY_ENTRY_ADDED' => "Eintrag hinzugefügt",
'ADMIN_HISTORY_ENTRY_LAST_USED' => "Zuletzt verwendet",
'ADMIN_ACTION_DELETE_HISTORY_SUBMIT' => "Alle Historie-Einträge löschen",
'ADMIN_LIST_HISTORY_NOTICE' => "<strong>Vorsicht:</strong> Mit Klick auf <strong>{--ADMIN_ACTION_DELETE_HISTORY_SUBMIT--}</strong> werden die Historie-Einträge sofort bereinigt, ohne zusätzliche Sicherheitsabfrage.",
+ // Admin - server_name_log - generic
+ 'ADMIN_LIST_SERVER_NAME_LOG_TITLE' => "Auflisten aller geloggten SERVER_NAME-Einträge",
+ 'ADMIN_ACTION_DELETE_LOG_SUBMIT' => "Gesamtes Logbuch löschen",
+ 'ADMIN_LIST_LOG_NOTICE' => "<strong>Vorsicht:</strong> Mit Klick auf <strong>{--ADMIN_ACTION_DELETE_LOG_SUBMIT--}</strong> wird das <u>gesamte</u> Logbuch sofort bereinigt, ohne zusätzliche Sicherheitsabfrage.",
+ 'ADMIN_TASK_LIST_SERVER_NAME_LOG' => "Logbuch für SERVER_NAME-Einträge",
+ 'ADMIN_TASK_LIST_SERVER_NAME_LOG_TITLE' => "Es sind geloggte SERVER_NAME-Logbucheinträge vorhanden.",
+ 'ADMIN_SERVER_NAME' => "Host-Kopfzeile",
+
// Admin - user's points amount
'ADMIN_LIST_USER_AMOUNTS_TITLE' => "Verteilung des {?POINTS?}-Gesamtvolumens",
'ADMIN_TOTAL_POINTS' => "Gesamtguthaben",
$TITLEs[] = '{--ADMIN_TASK_LIST_SURFBAR_URLS_PENDING_TITLE--}';
} // END - if
+ if (isExtensionInstalledAndNewer('sql_patches', '0.9.2')) {
+ // Check for accounts without referral
+ addSql('SELECT `server_name_id` FROM `{?_MYSQL_PREFIX?}_server_name_log`');
+ $DESCRs[] = '{--ADMIN_TASK_LIST_SERVER_NAME_LOG--}';
+ $TITLEs[] = '{--ADMIN_TASK_LIST_SERVER_NAME_LOG_TITLE--}';
+ $WHATs[] = 'list_server_name';
+ } // END - if
+
// Generate extra overview rows
$EXTRAS .= createExtraTaskRows($WHATs, $DESCRs, $TITLEs);
--- /dev/null
+<?php
+/************************************************************************
+ * Mailer v0.2.1-FINAL Start: 11/04/2012 *
+ * =================== Last change: 11/04/2012 *
+ * *
+ * -------------------------------------------------------------------- *
+ * File : what-list_server_name.php *
+ * -------------------------------------------------------------------- *
+ * Short description : List wrong SERVER_NAME entries *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung : Auflisten verkehrter SERVER_NAME-Eintraege *
+ * -------------------------------------------------------------------- *
+ * $Revision:: $ *
+ * $Date:: $ *
+ * $Tag:: 0.2.1-FINAL $ *
+ * $Author:: $ *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003 - 2009 by Roland Haeder *
+ * Copyright (c) 2009 - 2012 by Mailer Developer Team *
+ * For more information visit: http://mxchange.org *
+ * *
+ * 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. *
+ * *
+ * This program is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
+ * GNU General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU General Public License *
+ * along with this program; if not, write to the Free Software *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, *
+ * MA 02110-1301 USA *
+ ************************************************************************/
+
+// Some security stuff...
+if ((!defined('__SECURITY')) || (!isAdmin())) {
+ die();
+} // END - if
+
+// Display only title when no form was submitted
+addYouAreHereLink('admin', __FILE__);
+
+// Delete entries?
+if (isFormSent('do_delete')) {
+ // Remove entries from database
+ doGenericXmlTemplateCallback('admin_delete_do_server_name_log');
+} // END - if
+
+// List all entries per user
+doGenericXmlTemplateCallback('admin_list_server_name_log');
+
+// [EOF]
+?>
<td class="header_column bottom right" align="center"><strong>{--ID_SELECT--}</strong></td>
<td class="header_column bottom right" align="center"><strong>{--_USERID--}</strong></td>
<td class="header_column bottom right" align="center"><strong>{--ADMIN_HISTORY_VALUE--}</strong></td>
- <td class="header_column bottom right" align="center"><strong>{--ADMIN_HISTORY_ENTRY_ADDED--}</strong></td>
+ <td class="header_column bottom right" align="center"><strong>{--ENTRY_ADDED--}</strong></td>
<td class="header_column bottom" align="center"><strong>{--ADMIN_HISTORY_ENTRY_LAST_USED--}</strong></td>
</tr>
$content
--- /dev/null
+<div align="center">
+<form accept-charset="UTF-8" action="{%url=modules.php?module=admin&what=list_server_name%}" method="post">
+<table border="0" cellspacing="0" cellpadding="0" class="table dashed">
+<tr>
+ <td align="center" colspan="6" class="table_header">
+ <strong>{--ADMIN_LIST_SERVER_NAME_LOG_TITLE--}</strong>
+ </td>
+</tr>
+<tr>
+ <td class="header_column bottom right" align="center"><strong>{--ID_SELECT--}</strong></td>
+ <td class="header_column bottom right" align="center"><strong>{--ADMIN_SERVER_NAME--}</strong></td>
+ <td class="header_column bottom right" align="center"><strong>{--REMOTE_IP--}</strong></td>
+ <td class="header_column bottom right" align="center"><strong>{--USER_AGENT--}</strong></td>
+ <td class="header_column bottom right" align="center"><strong>{--REFERRER_URL--}</strong></td>
+ <td class="header_column bottom" align="center"><strong>{--ENTRY_ADDED--}</strong></td>
+</tr>
+$content
+<tr>
+ <td class="table_footer" colspan="6">
+ <input type="hidden" name="server_name_id[0]" value="1" />
+ <input type="submit" class="form_delete" name="do_delete" value="{--ADMIN_ACTION_DELETE_LOG_SUBMIT--}" />
+ </td>
+</tr>
+</table>
+</form>
+</div>
+
+<div class="notice">
+ {--ADMIN_LIST_LOG_NOTICE--}
+</div>
--- /dev/null
+<tr>
+ <td align="center" class="bottom right {%template,ColorSwitch%}">
+ <strong>$content[server_name_id]</strong>
+ </td>
+ <td align="center" class="bottom right {%template,ColorSwitch%}">
+ $content[server_name]
+ </td>
+ <td align="center" class="bottom right {%template,ColorSwitch%}">
+ $content[server_name_remote_addr]
+ </td>
+ <td align="center" class="bottom right {%template,ColorSwitch%}">
+ {%pipe,fixEmptyContentToDashes=$content[server_name_ua]%}
+ </td>
+ <td align="center" class="bottom right {%template,ColorSwitch%}">
+ {%pipe,generateDereferrerUrl,fixEmptyContentToDashes=$content[server_name_referrer]%}
+ </td>
+ <td align="center" class="bottom {%template,ColorSwitch%}">
+ $content[server_name_added]
+ </td>
+</tr>
--- /dev/null
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+This template provides meta data for listing nickname-change history entries.
+
+@author Roland Haeder <webmaster@mxchange.org>
+@version 0.2.1-FINAL
+@copyright (c) 2003 - 2009 by Roland Haeder
+@copyright (c) 2009 - 2011 by Mailer Developer Team
+@license GNU GPL 2.0 or any newer version
+@link http://mxchange.org
+
+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.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program; if not, write to the Free Software
+Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
+MA 02110-1301 USA
+//-->
+<admin-list-data>
+ <!--
+ Call-back function, the extracted data from this XML will then be re-read
+ from that function. The most common function this XML uses is
+ doGenericListEntries() so mostly you can leave this alone unless you have JOINs.
+ //-->
+ <callback-function type="string" value="doGenericListEntries" />
+ <!--
+ Now we need information which template should be loaded and which functions
+ shall be called back. So lets start with the main list template. This mostly
+ requires no call-back function.
+ //-->
+ <list-template type="string" value="admin_list_server_name_log" />
+ <!--
+ The template for all rows, mostly this name has a '_row' suffix and again,
+ no call-back function is usually required.
+ //-->
+ <list-row-template type="string" value="admin_list_server_name_log_row" />
+ <!--
+ Message id to display if no entry could be found
+ //-->
+ <no-entry-found-message type="string" value="ADMIN_LIST_SERVER_NAME_LOG_404" />
+ <!--
+ The table(s) we shall grab the data from, all as list.
+ //-->
+ <data-tables>
+ <!--
+ A single table entry, with alias and without the configurable
+ _MYSQL_PREFIX. You can specify the table's name or alias later on.
+ //-->
+ <data-table type="string" alias="" value="server_name_log" />
+ <!--
+ Columns to perform the SELECT statement on, with alias and name plus which table.
+ //-->
+ <select-data-from-list>
+ <!--
+ A single entry with table name (can be left empty), value (must
+ always be set), alias (again can be left empty) and SQL function
+ (can also be left empty) which shall be applied on the column.
+ //-->
+ <select-data-from-list-entry type="string" table="" value="server_name_id" alias="" function="" />
+ <select-data-from-list-entry type="string" table="" value="server_name" alias="" function="" />
+ <select-data-from-list-entry type="string" table="" value="server_name_remote_addr" alias="" function="" />
+ <select-data-from-list-entry type="string" table="" value="server_name_ua" alias="" function="" />
+ <select-data-from-list-entry type="string" table="" value="server_name_referrer" alias="" function="" />
+ <select-data-from-list-entry type="string" table="" value="server_name_added" alias="server_name_added" function="UNIX_TIMESTAMP" />
+ </select-data-from-list>
+ <!--
+ And the column list to perform the WHERE statement on.
+ //-->
+ <where-select-from-list>
+ </where-select-from-list>
+ <!--
+ Columns to perform the ORDER BY statement (GROUP BY is not yet supported)
+ //-->
+ <order-by-list>
+ <!--
+ A single entry to perform the ORDER BY statement on, see above WHERE entry for details.
+ //-->
+ <order-by-list-entry type="string" table="" order="server_name_added" value="DESC" />
+ </order-by-list>
+ </data-tables>
+ <!--
+ List all column names from the 'select-data-from-list' node here, but now
+ with call-back informations. The list must only contain those entries where
+ a call-back function shall be called for.
+ //-->
+ <column-callback-list>
+ <!--
+ Another column, now we need a second parameter here because
+ generateDateTime() expects two parameters (first is always the data
+ from column).
+ //-->
+ <column-callback-list-entry>
+ <!--
+ The actual data, again.
+ //-->
+ <column-callback-data type="string" value="server_name_added" callback="generateDateTime" />
+ <!--
+ More parameters, remember that the first parameter is always given
+ and that it is the data from column.
+ //-->
+ <callback-extra-parameter-list>
+ <!--
+ A single parameter, 'type' can be one of 'float', 'int',
+ 'bool', 'string'. 'array' is not yet supported.
+ //-->
+ <callback-extra-parameter-list-entry type="int" column="server_name_added" value="2" />
+ </callback-extra-parameter-list>
+ </column-callback-list-entry>
+ </column-callback-list>
+</admin-list-data>