Jump to content

Check type of the file not only on expansion in a file name, but also on heading in the file.


Recommended Posts

It will allow not to allow file load .psd with expansion on .jpg.

Example:
I have an external form. In type of a field it is specified (to allow.jpg.jpeg). But it is enough to rename only expansion as it will be possible to load and.psd and.png and.pdf and.php.
Besides, everyone will be processed on a miscellaneous, instead of as jpg.
 
For the sake of dough I suggest to load psd renamed into jpg
Link to comment
Share on other sites

Are you suggesting that a PSD file should be automatically renamed to a JPG file? Those are two very different file types. However, if you have the need to do that, I may be able to suggest a hook. But I anticipate you wouldn't be able to use any of the image manipulation functions on the renamed file without getting exceptions (unless PSDs can now pretend to be JPGs through some file data tricks). Regardless, a PSD is a full-blown Photoshop file and not an appropriate format for web storage unless you intend to distribute source files, in which case you'd definitely want to keep the PSD extension. 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...