Extract class for image path creation

It's implemented in the blog module.
It includes the module name, the site id and the language in the paths.