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?
Edited 9 years 11 months ago by Michael Yaeger