Scraptcha
Scraptcha provides a method of user validation for submission forms.
var express = ;var scraptcha = ; // Scraptcha images source information. var imageInformation = path: __dirname + "/images/green/" filePrefix: "i_cha_" fileExtension: ".gif"; // Initialize the Scraptcha data.scraptcha; // Static file server.var server = ;server;server;console; // Gets the scratcha code sequence. The "id" compensates for a browser update restriction. server; // Returns validation response.server;
Installation
$ npm install scraptcha
Features
- Image reference code entry
- Base64 image conversion
- Random code digit sizes
- Image digit warp
- Image order scrambling
- Image code verification
Quick Start
Reference files are located in the 'test' folder. Start the example server by navigating to the ./node_modules/scraptcha directory from the command prompt and perform the command "npm start" or "node ./test/file-server.js".
See the 'submit: function(){...}' in the 'main.js' file for end user form adaptation.
Use your own image base by creating a image cache and then edit 'imageInformation{...}' from the above example. Update 'scraptchaCode[...]' in the package 'index.js' file if the code sequence is different.