Adding a reason_for_ban column

kreynen - August 19, 2009 - 22:58
Project:Troll
Version:6.x-1.x-dev
Component:Code
Category:feature request
Priority:normal
Assigned:Unassigned
Status:active
Description

I wanted to show a banned user the reason they've been banned in addition to how long they are being banned and the body from the site's code of conduct. I pointed the IP Ban Relocation Page to a new php file with read access to the Drupal db. Then I added a reason_for_ban column to the troll_ip_ban table. I also included the nid of the code of conduct in the query string of the block.php file so if that node is updated I don't have to manually update it on the blocked.php.

AttachmentSize
troll.admin_.inc_.patch769 bytes
troll.module.patch1.6 KB

#1

kreynen - August 20, 2009 - 22:42

Should have included this in the previous post.

AttachmentSize
blocked.php.txt 2.02 KB

#2

kreynen - August 20, 2009 - 23:05

Don't use that first file. It made it pretty easy for users to browse your whole site. I've change the nid to be hardcoded into the php.

AttachmentSize
blocked.php.txt 2.01 KB
 
 

Drupal is a registered trademark of Dries Buytaert.