function isValidImage(imagename)
{

imagefile_value = imagename;
var checkimg = imagefile_value.toLowerCase();
if (!checkimg.match(/(\.jpg|\.gif|\.png|\.JPG|\.GIF|\.PNG|\.jpeg|\.JPEG)$/))
{
return false;
}
else
{
return true;
}
}

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.