JavaScript jQuery/javascript specific word detect

An improvement:

var seq = "rainbow"
var input = ""
window.addEventListener("keypress", function(e) {
    input += String.fromCharCode(e.keyCode)

    for (var i = 0; i < seq.length; i++) {
        if (input[i] != seq[i] && input[i] != undefined) {
            input = ""
        }
    }

    if (input == seq) {
        alert("EASTER EGG!")

        input = ""
    }
})
Answer:1

I have a relatively simple regex problem - I need to match specific words in a string, if they are entire words or a prefix. With word boundaries, it would look something like this: \b(word1|word2|...

I have a relatively simple regex problem - I need to match specific words in a string, if they are entire words or a prefix. With word boundaries, it would look something like this: \b(word1|word2|...

  1. javascript regex simulator
  2. js regex simulator

Let me cut to the chase. It's on this site: http://www.smb.nu/wip/kampanj/ The white bar with the links is supposed to stick to the top when scrolled past, this effect is achieved with some simple ...

Let me cut to the chase. It's on this site: http://www.smb.nu/wip/kampanj/ The white bar with the links is supposed to stick to the top when scrolled past, this effect is achieved with some simple ...

Quick question. Why does the following give a this.testFunction is not a function error? Test = { data: true, testFunction: function() { this.data = true; }, initialize: ...

Quick question. Why does the following give a this.testFunction is not a function error? Test = { data: true, testFunction: function() { this.data = true; }, initialize: ...

  1. simple javascript object
  2. simple javascript object example
  3. create simple object javascript

I have one text box. When I enter a date with the format MM/DD/YYYY in that textbox and click outside the textbox I need to display the result as MM/DD/YYYY+3 using JavaScript. For example, if my ...

I have one text box. When I enter a date with the format MM/DD/YYYY in that textbox and click outside the textbox I need to display the result as MM/DD/YYYY+3 using JavaScript. For example, if my ...

  1. 3 days given up smoking
  2. three days is given
  3. given three days notice
  4. three days grace given to me
  5. three days grace given to me скачать