• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Is there a way to convert webp to jpg using CF?

Explorer ,
Oct 24, 2021 Oct 24, 2021

Copy link to clipboard

Copied

I'm wondering if there is a way to convert webp to jpg on upload using CF?

Views

2.9K

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Enthusiast , Oct 24, 2021 Oct 24, 2021

I've encountered issues where Adobe ColdFusion wasn't able to read JPG photos from our clients that were created using an iPhone 4. As a result, we started using CFExecute with GraphicsMagick for all of our image transformations. (GM is also used by Etsy & Flickr.)  I've tested ImageMagick it also works.  (We also have IM installed so we can convert HEIF/HEIC images to JPG automatically upon upload.)


I used this WEBP image for testing:

https://www.gstatic.com/webp/gallery/1.webp

Original Filesize:

...

Votes

Translate

Translate
Enthusiast ,
Oct 24, 2021 Oct 24, 2021

Copy link to clipboard

Copied

I've encountered issues where Adobe ColdFusion wasn't able to read JPG photos from our clients that were created using an iPhone 4. As a result, we started using CFExecute with GraphicsMagick for all of our image transformations. (GM is also used by Etsy & Flickr.)  I've tested ImageMagick it also works.  (We also have IM installed so we can convert HEIF/HEIC images to JPG automatically upon upload.)


I used this WEBP image for testing:

https://www.gstatic.com/webp/gallery/1.webp

Original Filesize: 10,474

 

GraphicsMagick:

gm convert c:\test.webp c:\test.jpg

Resultant Filesize: 12,338

 

ImageMagic

magick c:\test.webp c:\test.jpg

Resultant Filesize: 25,132

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Oct 24, 2021 Oct 24, 2021

Copy link to clipboard

Copied

This is great. Thank you. Would you be willing to share a code sample? My knowledge is a bit limited.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Enthusiast ,
Oct 24, 2021 Oct 24, 2021

Copy link to clipboard

Copied

I provided simple command line examples to convert WEBP to JPG using both GraphicsMagick and ImageMagick.  Install either.  After a file with the "webp" extension is uploaded, perform the conversion using the CFExecute tag.

 

If you need help regarding how to use CFExecute, documentation is available here:
https://cfdocs.org/cfexecute

 

If you are unable to install ImageMagick or GraphicsMagick on your server, you may want to consider using a third-party API.  Here are some that I found while searching for "WEBP to JPG API'.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Oct 24, 2021 Oct 24, 2021

Copy link to clipboard

Copied

Thank you again!

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
May 15, 2023 May 15, 2023

Copy link to clipboard

Copied

LATEST

At the time I posted this question, I was on a shared server and not able to install apps. I am now in the process of migrating to a private server where I have more control. I have installed both ImageMagick and GraphicsMagick on my server. With regard to converting files, both of these options work great. Very easy to setup and use. These worked out to be excellent solutions for me.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
May 15, 2023 May 15, 2023

Copy link to clipboard

Copied

If you're looking to convert your WebP images to JPG format, one option you can try is the online converter tool available at Webp To Jpg Converter. This tool allows you to quickly and easily convert your WebP files to JPG format without having to download any additional software.

To use the tool, simply upload your WebP file to the website, select "JPG" as the output format, and then click the "Start Conversion" button. The tool will then convert your file and provide you with a download link for the resulting JPG image.

Alternatively, if you're looking for a more robust image editing solution, you can consider using Adobe Photoshop or Adobe Lightroom to convert your WebP images to JPG format. Both of these programs offer advanced image editing capabilities, including the ability to convert images to different formats, adjust color and brightness, and more.

I hope this helps! Let me know if you have any other questions.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Enthusiast ,
May 15, 2023 May 15, 2023

Copy link to clipboard

Copied

Please re-read the original poster's question... "using CF".  Your response requires manual effort and doesn't involve CF at all.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
May 15, 2023 May 15, 2023

Copy link to clipboard

Copied

hi can you remove my last answer, because users can't edit or delete the post.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation