regex modified to support both html and markdown images

Generified the regex a bit, thanks for creating!