var location=$("input[name='file']").val(); var point = location.lastIndexOf("."); var type = location.substr(point); if(type==".jpg"||type==".gif"||type==".JPG"||type==".GIF"){ }
var location=$("input[name='file']").val(); var point = location.lastIndexOf("."); var type = location.substr(point); if(type==".jpg"||type==".gif"||type==".JPG"||type==".GIF"){ }