More robust retina file naming

Previous str_replace() retina file naming causes errors if the path
contains periods (.), so replaced file naming with pathinfo()