Download & Extend

Adding a reason_for_ban column

Project:Troll
Version:6.x-1.x-dev
Component:Code
Category:feature request
Priority:normal
Assigned:Unassigned
Status:active

Issue Summary

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

Comments

#1

Should have included this in the previous post.

AttachmentSize
blocked.php.txt 2.02 KB

#2

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