Update remote URL behaviour to allow retrieving remote image with Query String urls

Before this, when the remote URL contains a query string (?photoId=18) the file can't be retrieved on some Apache version.
Now the query string is append to the path and check correctly. These files are always served by the controller because of this specificity but are always accessible and resizable.

Signed-off-by: Stéphane HULARD <s.hulard@chstudio.fr>
Use getimagesize if exif_imagetype does not exists

On some servers, the exif_imagetype is not accessible. Rely to getimagesize which is a little slower to access image type.
If these 2 methods are not allowed, just use the standard extension detection which is not really cool...

Signed-off-by: Stéphane HULARD <s.hulard@chstudio.fr>