//Word limit in Post //Written by slayer766 of thecodingzone.com function countWords(heyslay){ heyslay=heyslay.split("\n").join(" "); chocolate=heyslay.split(" "); heyslay=0; for(da=0;da0){ heyslay++; } } return heyslay; } $("button.btn_default").click(function(){ Locate = ""; if(document.forms['posting']){ Locate = countWords(document.forms['posting'].post.value); } if(document.getElementsByTagName("textarea")[0]){ Locate = countWords(document.getElementsByTagName("textarea")[0].value); } for(c in The_Forums){ if(location.href.match("&f="+The_Forums[c]) || location.href.match(/\/topic\//i)){ if(Locate < Limit){ alert(message+"\n"+Math.floor(Limit - Locate)+" more words needed!"); return false; } } } });