Posted on: 9/5/2014 1:20:45 PM | Views : 399

Hi guys,
 
Can you confirm what i have done is sufficient to stop spam.
When the page loads:
@{
    Layout = "Layout.cshtml";
    int aNumber = new Random().Next(1, 3);
    int bNumber = new Random().Next(1, 11);
    var errorPrintOut = "";
    bool contactSent = false;
}
 
The numbers are displayed to the user to add:
<label id="captchaCheckLabel" for="captchaCheck">@aNumber + @bNumber =</label><p style="color:red; font-size: 20px;">@errorPrintOut</p>
 <input type="hidden" name="nA" value="@aNumber" />
  <input type="hidden" name="nB" value="@bNumber" />
<input id="captchaCheckInput" name="captchaCheck" type="t ...

Go to the complete details ...