dey Wrote:Last week I reported my issue at the forum of hostingsociety. The reply was something like "bad coding" and too much resource consuming.
What is meant is the huge number os calls of pic.php likeCode:<img src="http://deynews.hostingsociety.com/plugins/i18n_gallery/browser/pic.php?g=top-10&p=images%2F%2Fnatur%2Fstart.jpg&w=120&h=80" alt="Meine Top 10" title="Meine Top 10"/>
The main reason for routing all image requests through pic.php is the resizing of thumbs and images on-the-fly to the thumb and image sizes requested.
As you can specify a different thumb or image size in the call, this is the only way to do it, e.g. if you specify a fancybox gallery mygallery with thumb sizes 120x90, you can also call the gallery with (% gallery type=prettyphoto thumbwidth=160 thumbheight=120 %).
So resizing the images when defining the gallery won't work, and resizing all images on page load would take too much time.
A second reason is that I want to limit access to the images and show some images only to registered users.
I'll try to implement a better method:
- if no veto filter for images is registered and the thumbnail/image exists, link to the image file.
- otherwise, if the image needs to be resized, pic.php should resize the image and redirect either to the image or to a script checking access rights
- otherwise links to the script checking access rights.