[RC]Simple Spam Links Breaker

A place for MOD Authors to post and receive feedback on MODs still in development. No MODs within this forum should be used within a live environment! No new topics are allowed in this forum.
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

IMPORTANT: MOD Development Forum rules

On February 1, 2009 this forum will be set to read only as part of retiring of phpBB2.
Post Reply
User avatar
polkadotcat
Registered User
Posts: 53
Joined: Thu Jun 23, 2005 11:11 pm
Contact:

[RC]Simple Spam Links Breaker

Post by polkadotcat »

Code: Select all

############################################################## 
## MOD Title: Simple_Spam_Links_Breaker 
## MOD Author: polkadotcat < N/A > (N/A) http://alwayskeela.awardspace.com/forum
## MOD Description: Very simple edits which will prevent spammer links
##                  from working on your forum. Used in conjunction 
##                  with your word censors to break:
##                   within posts:
##                    inappropriate links in posts
##                    inappropriate links in www buttons
##                    inappropriate links in signatures
##                   with user profile
##                    inappropriate links in website url
##                    inappropriate links in www buttons (if used)
##                   within memberlist:
##                    inappropriate links in www buttons.
## MOD Version: 1.0.0 
## 
## Installation Level: (Easy) 
## Installation Time: 3 Minutes 
## Files To Edit: memberlist.php
##                viewtopic.php
##                includes/usercp_viewprofile.php
## Included Files: (N/A) 
## License: http://opensource.org/licenses/gpl-license.php GNU General Public License v2 
############################################################## 
## For security purposes, please check: http://www.phpbb.com/mods/ 
## for the latest version of this MOD. Although MODs are checked 
## before being allowed in the MODs Database there is no guarantee 
## that there are no security problems within the MOD. No support 
## will be given for MODs not found within the MODs Database which 
## can be found at http://www.phpbb.com/mods/ 
############################################################## 
## Author Notes: This is a way to stop those spam links from working 
## while your admins are away and unable to delete the spam posts before 
## forum users see them. 
## 
## Usually when a spam post with a p0rn link gets posted sometimes your 
## admins may not get to it in time before a user clicks it. Whenever 
## links like this crop up on a forum admins delete the post and implement 
## a word censor to block the site link should it get posted again... 
## this obviously doesn't work though because although the post shows the 
## replacement words, the actual correct link is shown when the mouse is 
## hovered over it... so when it gets clicked, that 14 year old member 
## you have viewing your forum, has just whisked off to see the p0rn 
## site from the link. 
## eg: www.freepor.com would show as www.[spam link].com or whatever
## you have as the replacement word but would still take the user to 
## www.freepor.com 
## 
## The thing was... in topic review the censored spamlink will show 
## correctly as being broken... 
## eg: www.freepor.com became www.[spam link].com and the link itself 
## would be www.[spam link].com 
## 
## What this little mod will do is make the post link look and behave 
## like it does in topic_review, rendering the link totally useless and 
## unworkable to forum users!! And still allows mod/admin to see the 
## actual words used by the poster when edit button on the spam post is 
## clicked... Very helpful if your board is spammed with links a lot, 
## and you get worried about the minors visiting any innappropriate links. 
## This will also break the www button link in the spammers post as well
## as breaking the link in their profile, and in the memberlist.
## 
## Note: This is used in conjunction with your word censors. 
## Demo: http://alwayskeela.awardspace.com/forum/viewtopic.php?p=47#47
## Please note I did not write the actual code, I can't code php to 
## save myself.  All I did was use the existing vanilla phpbb code for
## the topic_review.php page and moved it to other pages to  break 
## links containing censored words.
##
## And YES there are 2 find commands on viewtopic.php before replace
## with... this was to make it easier to find the correct portion of
## code to edit, it is not a typo.
############################################################## 
## MOD History: 
## 
##   2006-11-26 - Version 1.0.0 
##      - this is the first and only version 
##        compatible with phpbb 2.0.21 
## 
############################################################## 
## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD 
############################################################## 
  • MOD Title: Simple_Spam_Links_Breaker
    MOD Description:
    • Works in conjuction with your forum's word censors to break:
      inappropriate links in forum posts
      inappropriate links in signatures
      inappropriate links in www buttons on posts
      inappropriate links in www buttons in memberslist
      inappropriate links in url or www button in user profile

      Links in posts which are censored cannot be quoted.
      Mod/Admins can view uncensored links in posts only by editing censored post.
      Admins can view uncensored signatures & website links in ACP => User Management on user's profile... hopefully only to be seen when they go to delete the member.

      All links are still clickable, they just won't go where the poster wants them to go, if part or all of the domain name of the site you want to block is in your word censor list.
    MOD Version: 1.0.0
    MOD Download: download as .txt file click the link and when the little box comes up, choose save, then save as .txt
    Last Stable version: N/A

    Demo: here
    Note: admin privileges must be set to view changes in effect to a user's profile in the ACP... and they are NOT set on my demo boards, so you cannot view those changes... but they do indeed take place... there are member and mod accounts for testing purposes listed on demo boards index pages..

    This is an expansion of this topic

    I have submitted this to the MOD DB whether it will be approved or not... who knows?!?...
    I'm putting it up for those who don't want to install the big anti-spam mods, or who don't get that many spam posts..

    Please note: I can't write php code, so I won't really be able to help anyone if they have issues with this conflicting with other mods they have.
Last edited by polkadotcat on Sat Dec 09, 2006 1:43 am, edited 3 times in total.
I'm just a girl in the world...
polkadotcat's wee world...
Rebell
Registered User
Posts: 93
Joined: Tue Nov 08, 2005 8:31 am
Contact:

Post by Rebell »

Looks easy and interisting !

will try out :D
OLDSKOOLDEMOMAKER FORUMS : http://kickme.to/osdm
make demos like in the good old days on amiga or c64 without programming knowledge !
User avatar
polkadotcat
Registered User
Posts: 53
Joined: Thu Jun 23, 2005 11:11 pm
Contact:

Post by polkadotcat »

Cool.. well let me know if you found it in any way useful or problematic.
I'm just a girl in the world...
polkadotcat's wee world...
User avatar
A_Jelly_Doughnut
Former Team Member
Posts: 34457
Joined: Sat Jan 18, 2003 1:26 am
Location: Where the Rivers Run
Contact:

Post by A_Jelly_Doughnut »

A bit of a bug: There is $www_img as well as another variable without the image. I think it is called $user_www, but it might just be $www. This appears at least in viewtopic.php, possibly also memberlist.php

If you need help implementing that, I won't mind if you PM me 8)
A Donut's Blog
"Bach's Prelude (Cello Suite No. 1) is driving Indiana country roads in Autumn" - Ann Kish
User avatar
polkadotcat
Registered User
Posts: 53
Joined: Thu Jun 23, 2005 11:11 pm
Contact:

Post by polkadotcat »

Please look at the code on the download and not on the link to my previous topic..

$www_img is already included in the code to block the www buttons, as is $www to block url links... so where is the bit of a bug?
I'm just a girl in the world...
polkadotcat's wee world...
User avatar
polkadotcat
Registered User
Posts: 53
Joined: Thu Jun 23, 2005 11:11 pm
Contact:

Post by polkadotcat »

I have found another code which I am currently using on the demo forum, which will allow Admins to receive uncensored PM's for those of you interested its here.
I'm just a girl in the world...
polkadotcat's wee world...
Post Reply

Return to “[2.0.x] MODs in Development”