Welcome to WebmasterWorld Guest from 34.207.152.62

Forum Moderators: brett tabke

Message Too Old, No Replies

Notify users when they try to post a URL

     
7:09 pm on May 28, 2010 (gmt 0)

Senior Member from US 

WebmasterWorld Senior Member fotiman is a WebmasterWorld Top Contributor of All Time 10+ Year Member Top Contributors Of The Month

joined:Oct 17, 2005
posts:5019
votes: 24


When a user submits a post, it might be helpful if they received some sort of notification if their post contains a URL. For example, maybe something along the lines of "Your post contains a URL. Have you read the Terms of Service regarding URLs?" [Yes] [No]. Often times a new user is not aware of the policies, so bringing attention to the fact that they might be about to violate the TOS might cut down on the number of posts that contain URLs in violation of the TOS (and therefore cut down on the number of users that get moderated). Just an idea.
8:21 pm on May 28, 2010 (gmt 0)

Senior Member

WebmasterWorld Senior Member g1smd is a WebmasterWorld Top Contributor of All Time 10+ Year Member Top Contributors Of The Month

joined:July 3, 2002
posts:18903
votes: 0


There's certainly a need to flag to people that they should use http://example.com/ and http://www.example.com/ when they post code examples.

Using [mydomain.com...] and others currently results in a b0rked piece of code and moderator time being used to fix every such post.

This is certainly a problem in the /apache forum here, and perhaps in the PHP or IIS forums too.
8:26 pm on May 28, 2010 (gmt 0)

Junior Member

5+ Year Member

joined:May 26, 2010
posts: 92
votes: 0


This forum parses text to filter out vulgar language, and replaces it with grawlixes: "@#$%&!"

The same method could be used to identify links with a regular expression, and replace it with text like:
***link removed***
Eventually, users would learn posting links is futile.
8:42 pm on May 28, 2010 (gmt 0)

Senior Member

WebmasterWorld Senior Member g1smd is a WebmasterWorld Top Contributor of All Time 10+ Year Member Top Contributors Of The Month

joined:July 3, 2002
posts:18903
votes: 0


Please define "a link" for all instances of "link".

Is this a link?

RewriteRule ^cat-([0-9]+)/prod-([0-9]+)$ http://www.example.com/p$1 [R=301,L]



See also: [webmasterworld.com...]
8:55 pm on May 28, 2010 (gmt 0)

Junior Member

5+ Year Member

joined:May 26, 2010
posts: 92
votes: 0


Or, use a Regular Expression:

^(?#Protocol)(?:(?:ht|f)tp(?:s?)\:\/\/|~\/|\/)?(?#Username:Password)(?:\w+:\w+@)?(?#Subdomains)(?:(?:[-\w]+\.)+(?#TopLevel Domains)(?:com|org|net|gov|mil|biz|info|mobi|name|aero|jobs|museum|travel|[a-z]{2}))(?#Port)(?::[\d]{1,5})?(?#Directories)(?:(?:(?:\/(?:[-\w~!$+|.,=]|%[a-f\d]{2})+)+|\/)+|\?|#)?(?#Query)(?:(?:\?(?:[-\w~!$+|.,*:]|%[a-f\d{2}])+=?(?:[-\w~!$+|.,*:=]|%[a-f\d]{2})*)(?:&(?:[-\w~!$+|.,*:]|%[a-f\d{2}])+=?(?:[-\w~!$+|.,*:=]|%[a-f\d]{2})*)*)*(?#Anchor)(?:#(?:[-\w~!$+|.,*:=]|%[a-f\d]{2})*)?$


Of course, there's a large number of country code domain extensions...they would need to be added to the toplevel domains subexpression.

[edited by: engine at 11:18 am (utc) on May 30, 2010]

1:14 am on May 30, 2010 (gmt 0)

Senior Member

WebmasterWorld Senior Member g1smd is a WebmasterWorld Top Contributor of All Time 10+ Year Member Top Contributors Of The Month

joined:July 3, 2002
posts:18903
votes: 0


Yeah, but that would still b0rk my valid code example.

See also: almost any thread in the Apache forum.
 

Join The Conversation

Moderators and Top Contributors

Hot Threads This Week

Featured Threads

Free SEO Tools

Hire Expert Members