if thisLink ends with ".jpg" or thisLink ends with ".JPG" or thisLink ends with ".jpeg" or thisLink ends with ".JPEG" or thisLink ends with ".gif" or thisLink ends with ".GIF" or thisLink ends with ".png" or thisLink ends with ".PNG" then