Unfortunately that's not an actual error message, just a chunk of code from the gallery, so it doesn't tell me a great deal. Was there any more to it?
With that limited information, my only guess would be either that the files were somehow corrupted in the download/unzipping process, or you have a permissions issue. I'm not sure it'll show anything helpful, but if you open the console on the main menu (press shift + O) it should show a list of the images that were loaded for the gallery if it's all working, which is actually the exact piece of code you posted.
Would you mind telling me what platform you're using, and if you're using any third party mods? I have known translation mods to cause issues with the galleries.