Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function(request, sender, sendResponse) {
- var array = new Array();
- array = request.checkme.split(',');
- if(request.pattern == 'A') {
- for(stringbit in array){
- var regex = new RegExp(stringbit, "i");
- if (regex.test(document.body.innerHTML)) {
- sendResponse({findresult: "yes"});
- alert(request.checkme + " has been found!");
- } else {
- //Snub them.
- sendResponse({});
- }
- }
Add Comment
Please, Sign In to add comment