I have used the wordpress add_image_size
function on my theme function.php
and works fine but not for what I need.
I use the function in the soft proportional crop mode ex: add_image_size('mySIZE', 420, 9999)
witch means that the height of the image will change
and the file name will be like "image_name-420x230.jpg".
Because I'm getting the image via AJAX I need the file name, the width will be 420 but I don't know the height of each image that I upload.
what I need is a function that resize and give the file a name without the height ex "image_name-420.jpg"
any idea on how to do this?
Thanks!