quote:
Originally posted by Mattike
var gotThanks = msg.indexOf("thanks");
var gotThnx = msg.indexOf("thnx");
var gotThankyou = msg.indexOf("thank u");
if(gotThanks != -1 || gotThnx != -1 || gotThankyou) {
ChatWnd.SendMessage("No problem, " + User + "! ");
}
thats got to be the worst code Ive ever seen , even segosa wouldnt do that :--o.
code:
if(msg.match(/thanks|thnx|thank u/)){
ChatWnd.SendMessage("No problem, " + User + "! ");
}