summaryrefslogtreecommitdiff
path: root/modules/ban.module
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2001-01-13 16:33:19 +0000
committerDries Buytaert <dries@buytaert.net>2001-01-13 16:33:19 +0000
commit8b4c95b259089c54331e9a6d014495c1ec807cea (patch)
treef034ed8a5ad4c13ddd9c558857b7011f7cc1dceb /modules/ban.module
parentf9e5aa52ccad84784d8e134129f531751ccd34b2 (diff)
downloadbrdo-8b4c95b259089c54331e9a6d014495c1ec807cea.tar.gz
brdo-8b4c95b259089c54331e9a6d014495c1ec807cea.tar.bz2
- rewrote the block placement stuff and updated the themes.
IMPORTANT: you have to drop 2 tables "blocks" and "layout" and you have to recreate them again with those in database/database.mysql - integrated the documentation written by UnConeD
Diffstat (limited to 'modules/ban.module')
-rw-r--r--modules/ban.module30
1 files changed, 28 insertions, 2 deletions
diff --git a/modules/ban.module b/modules/ban.module
index 05f3efcdd..f602c177f 100644
--- a/modules/ban.module
+++ b/modules/ban.module
@@ -1,10 +1,33 @@
<?
-$module = array("admin" => "ban_admin");
+$module = array("help" => "ban_help",
+ "admin" => "ban_admin");
include "includes/ban.inc";
+function ban_help() {
+ ?>
+ <P>The ban module keeps a list of bans in four categories:</P>
+ <UL>
+ <LI>E-mail bans: this type of ban specifies which email-addresses will be rejected when registering new users. Can be used to prevent users from using a free-mail account (e.g. hotmail.com).</LI>
+ <LI>Profanity bans: <I>under construction</I></LI>
+ <LI>Hostname bans: this type of ban allows you to block certain hostnames to access to your site or to register as a new user.</LI>
+ <LI>Username bans: this ban will block certain usernames from registration. Typical examples include <I>admin</I>, <I>anonymous</I>, <I>root</I>, <I>webmaster</I>, etc.</LI>
+ </UL>
+ <P>The ban system allows you to use a flexible wild-card ban system. This means you can block all email addresses from a certain domain name, block every username starting with "guest", etc. To do this, you can use the following wild-card characters:</P>
+ <UL>
+ <LI>&nbsp;% : matches any number of characters, including zero characters.</LI>
+ <LI>&nbsp;_ : matches exactly one character.</LI>
+ </UL>
+ <P><U>Examples</U>:</P>
+ <UL>
+ <LI>E-mail address bans <CODE>%@hotmail.com</CODE>, <CODE>%@altavista.%</CODE>, <CODE>%@usa.net</CODE>, etc. Used to prevent users from using free-email accounts, which might be used to cause trouble.</LI>
+ <LI>Username bans <CODE>root</CODE>, <CODE>webmaster</CODE>, <CODE>admin%</CODE>, etc. Used to prevent administrator impersonators.</LI>
+ </UL>
+ <?
+}
+
function ban_admin_new($mask, $category, $reason) {
ban_add($mask, $category, $reason, &$message);
$output .= "$message\n";
@@ -97,7 +120,7 @@ function ban_admin_check() {
function ban_admin() {
global $op, $id, $mask, $category, $reason;
- print "<SMALL><A HREF=\"admin.php?mod=ban&op=add\">add ban</A> | <A HREF=\"admin.php?mod=ban&op=check\">check ban</A> | <A HREF=\"admin.php?mod=ban\">overview</A></SMALL><HR>\n";
+ print "<SMALL><A HREF=\"admin.php?mod=ban&op=add\">add ban</A> | <A HREF=\"admin.php?mod=ban&op=check\">check ban</A> | <A HREF=\"admin.php?mod=ban\">overview</A> | <A HREF=\"admin.php?mod=ban&op=help\">help</A></SMALL><HR>\n";
switch ($op) {
case "Add ban":
@@ -110,6 +133,9 @@ function ban_admin() {
case "add":
ban_admin_add();
break;
+ case "help":
+ ban_help();
+ break;
case "check":
ban_admin_check();
break;