Closed dimalebid closed 1 year ago
vendor/ctessier/nova-advanced-image-field/src/TransformableImage.php on the line 167
$this->image->save();
replaced with $this->image->save('public',80, 'jpg');
The error has gone, but there is God, does not save the cut -up picture, retains oreginal.
Use AdvancedImage::make('Photo')->croppable()
Hello @dimalebid,
I closed your issue because it was not proven yet that it is related to the package. I was never able to reproduce it. It was raised multiple times and the same issue in the Intervention repo is still opened, meaning it was not solved on their side yet either.
Are you able to provide to me the image your are working with? Please make sure the file has a defined extension.
I cannot make the modification you suggest, as it forces the output's quality and extension.
Hello @ctessier I am using code: AdvancedImage::make('Photo')->croppable()
https://prnt.sc/MtPKCtEz7qCk (like this). Where can I specify the image format? maybe some other code is needed to make it work properly?
Hello @ctessier I am using code:
AdvancedImage::make('Photo')->croppable()
https://prnt.sc/MtPKCtEz7qCk (like this). Where can I specify the image format? maybe some other code is needed to make it work properly?
The way you use the package doesn't really matter. It just takes the original file and use Intervention to transform it and save it. Nothing is changed in terms of format or extension.
Do you have this error with all your images? I guess not.
A simple Google search gave me this result: https://stackoverflow.com/a/50067359/2291873 Please check your file properties (including name and MIME type).
https://drive.google.com/file/d/1W-0efGWBJ2vwJ1pSDaIyGeRWzEnPZul3/view?usp=share_link "laravel/framework": "^9.19", "laravel/nova": "~4.0", "ctessier/nova-advanced-image-field": "^2.0.2",
Images: https://drive.google.com/file/d/1x0SS6AJzRQRGwUx3NsuzFSqammr5cUAO/view?usp=share_link https://drive.google.com/file/d/11f6mQrstQjqF2Mbpw8o7LIwEU18aTkcz/view?usp=share_link
Developing on localhost (OpenServer)
https://drive.google.com/file/d/1W-0efGWBJ2vwJ1pSDaIyGeRWzEnPZul3/view?usp=share_link "laravel/framework": "^9.19", "laravel/nova": "~4.0", "ctessier/nova-advanced-image-field": "^2.0.2",
Images: https://drive.google.com/file/d/1x0SS6AJzRQRGwUx3NsuzFSqammr5cUAO/view?usp=share_link https://drive.google.com/file/d/11f6mQrstQjqF2Mbpw8o7LIwEU18aTkcz/view?usp=share_link
Developing on localhost (OpenServer)
Thank you @dimalebid for all these details. I cannot reproduce on my end (using WSL and DevContainers) but I have a trail. Is your server running on Windows?
yes
Please try that branch and let me know: composer require "ctessier/nova-advanced-image-field":"dev-fix-unsupported-format-windows"
I couldn't reproduce as I am not on Windows but I think it might do the job.
Like you suggested in a previous comment, forcing the path seems to help, otherwise the extension cannot be resolved for some reason on Windows and ends up being tmp
, which is not supported.
I still think this is a issue with Intervention, but let's see if that workaround helps. Thank you for your help 😉
Hello, yes it works great
Hello, yes it works great
Great, thank you! I'll try to publish a new version tonight.
Thank you again for your help!
Why are you immediately closing the topic? the issue is not resolved with the problem "Encoding format (tmp) is not supported."! the problem is in the plugin, as it seems to me, and not in https://github.com/Intervention/image
You are using a package in which the error or something has changed there.