Welcome to the IMTalk - Internet Marketing & SEO Forum.
  • Login:
+ Reply to Thread
Results 1 to 2 of 2
  1. #1
    Phil Tanny is offline IM & SEO Whisperer Phil Tanny is on a distinguished road
    Join Date
    Aug 2011
    Posts
    33
    Thanks Given
    0
    Thanked 3 Times in 3 Posts

    Blocking Spam With Javascript

    Hi all,

    Coder Will Bontrager (willmaster.com) shared this spam busting tip with me, and I thought you might find it useful.

    ---------------

    One of the easiest form spam reduction techniques is to put a URL in the form's action tag that goes to a regular page instead of the form handling script - a real page, not a 404, so spammers don't get notified to manually investigate your code.

    Somewhere below the form, JavaScript assigns the correct URL to the action tag.

    The form tag needs an id value for the JavaScript to use. Example:

    <form id="handle" action="/index.html"> ... </form>

    <script type="text/javascript"> document.getElementById("handle").action = "/script.php"; </script>

    Spammers' robots seldom parse JavaScript, so their automated submission never reaches the form handler specified by the JavaScript.

    Instead, their spam goes poof at the URL hard coded into the form tag.

  2. #2
    flashas's Avatar
    flashas is offline IM & SEO Whisperer flashas is on a distinguished road
    Join Date
    Mar 2011
    Location
    Ireland
    Posts
    91
    Thanks Given
    11
    Thanked 7 Times in 6 Posts
    Thanks for great sharing
    Irish shop of Electronic Cigarettes


 

Similar Threads

  1. Do not SPAM
    By talk1234 in forum Social Networks & Community Websites
    Replies: 14
    Last Post: 07-24-2012, 12:01 PM
  2. How to pass a PHP variable to Javascript
    By Trek in forum Programming, Scripting, Database, Testing, Debugging...
    Replies: 5
    Last Post: 09-02-2011, 11:19 AM
  3. Wordpress Spam Comments Remover
    By proseocontent in forum Free Stuff
    Replies: 5
    Last Post: 07-06-2011, 02:09 PM
  4. (targeted) Link Request Vs. Spam
    By Hajoless in forum Link Building General Talk
    Replies: 0
    Last Post: 06-16-2011, 08:16 AM
  5. SPAM Comments Are Your Friend (Here's Why)
    By perada in forum CMS, Blogs, Blogging, Forums...
    Replies: 21
    Last Post: 05-17-2011, 09:35 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts