Keyword

[SOLVED] K2 image cache rebuild

More
7 years 11 months ago #159763 by Michael Yaeger
Replied by Michael Yaeger on topic [SOLVED] K2 image cache rebuild

Michael Yaeger wrote: We've added watermarks to all images in the site and replaced them on the server. However, K2 items do not display the updated images. Is running the above mentioned script required?

Please Log in or Create an account to join the conversation.

More
7 years 11 months ago - 7 years 11 months ago #159777 by Michael Yaeger
Replied by Michael Yaeger on topic [SOLVED] K2 image cache rebuild
OK, I was able to run the script, but it simply took the images in the `src` directory and rebuilt them in the `cache` directory, which was not what I needed. My images were in the same location as when I uploaded them (Joomla! `images` directory). I was able to use this extension (K2 Import) to rewrite all the images by exporting the K2 database and importing it, again, since the extension gives you the option to choose the image source directory:
www.individual-it.net/en/Joomla/View-category.html

However, I still need a solution to rebuild the category images. It seems K2 discards the original image file location and rewrites all the images in the database and on the server with the category ID as the filename. That means all the information about the original file is LOST!

So, how can I rebuild all K2 category images from the original files in the Joomla! images folder?
Last edit: 7 years 11 months ago by Michael Yaeger.

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
7 years 11 months ago #159787 by Krikor Boghossian
Replied by Krikor Boghossian on topic [SOLVED] K2 image cache rebuild
Unfortunately you will have to manually reupload these images.

JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.

More
7 years 11 months ago #159815 by Michael Yaeger
Replied by Michael Yaeger on topic [SOLVED] K2 image cache rebuild

Krikor wrote: Unfortunately you will have to manually reupload these images.


I don't believe manually going into 481 categories in the K2 admin to upload images is a recommended task.

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
7 years 11 months ago #159831 by Krikor Boghossian
Replied by Krikor Boghossian on topic [SOLVED] K2 image cache rebuild
I am sorry but this task is not included in that extension.
You can use an automation tool like Grunt if you want to downsize your images, if you are looking to decrease the size.

JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.

More
7 years 2 weeks ago #165160 by TheAnt
Replied by TheAnt on topic [SOLVED] K2 image cache rebuild
Hello
I used the script with a J! 3.8.1/K2 2.8.0 site to resize the cached images. It worked to recreate the cache, but now I don't see the items main images anymore. If I open every item, no image is available in image tab. Maybe because the script used a different name for the cached files?

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
7 years 2 weeks ago #165208 by Krikor Boghossian
Replied by Krikor Boghossian on topic [SOLVED] K2 image cache rebuild
Are you getting any 403/404 errors in your console?

JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.

More
7 years 2 weeks ago #165238 by TheAnt
Replied by TheAnt on topic [SOLVED] K2 image cache rebuild

Krikor wrote: Are you getting any 403/404 errors in your console?

Yes, but for:
fontawesome-webfont.ttf Failed to load resource: the server responded with a status of 404 (Not Found)

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
7 years 1 week ago #165245 by Krikor Boghossian
Replied by Krikor Boghossian on topic [SOLVED] K2 image cache rebuild
Do you have any backups to compare the filenames?

JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.

More
7 years 1 week ago #165276 by TheAnt
Replied by TheAnt on topic [SOLVED] K2 image cache rebuild
Hi Krikor
looking at the backup copy I see that the script ha created only a few files, into the cache there are 876 files, into the K2 media items one there are just some dozen.

Please Log in or Create an account to join the conversation.


Powered by Kunena Forum