[serendipity_event_imageselectorplus] wrong size for thumbs

Found a bug? Tell us!!
Post Reply
bernd_d
Regular
Posts: 468
Joined: Thu Jun 03, 2010 9:28 am
Contact:

[serendipity_event_imageselectorplus] wrong size for thumbs

Post by bernd_d »

landscape-thumbnails of gallery seems not to get correct width/height...
screenshot of output.png
screenshot of output.png (136.89 KiB) Viewed 6295 times
Settings:
version: 0.32
Maximum height of thumbnail (discards width) is on "150", width is on "0"
Dynamically resize images based on width and height attributes is set to "No"

The thumbnail-images in media-database are all on 150px height.

This is the output of html...

Code: Select all

<div class="serendipity_mediainsert_gallery">
  <div class="serendipity_imageComment_left" style="width: 100px">
      <div class="serendipity_imageComment_img">
      <a rel="prettyPhoto" class="serendipity_image_link" href="/uploads/Urlaub/2012-08-Berlin/Charlottenburg/P1020601.JPG" title="">
        <!-- s9ymdb:795 -->
        <img width="100" height="150" src="/uploads/Urlaub/2012-08-Berlin/Charlottenburg/P1020601.serendipityThumb.JPG">
      </a>
      </div>
      <div class="serendipity_imageComment_txt">P1020601</div>
  </div>
  <div class="serendipity_imageComment_left" style="width: 150px">
      <div class="serendipity_imageComment_img">
      <a rel="prettyPhoto" class="serendipity_image_link" href="/uploads/Urlaub/2012-08-Berlin/Charlottenburg/P1020604.JPG" title="">
        <!-- s9ymdb:795 -->
        <img width="150" height="100" src="/uploads/Urlaub/2012-08-Berlin/Charlottenburg/P1020604.serendipityThumb.JPG">
      </a>
      </div>
      <div class="serendipity_imageComment_txt">P1020604</div>
  </div>
  <div class="serendipity_imageComment_left" style="width: 150px">
      <div class="serendipity_imageComment_img">
      <a rel="prettyPhoto" class="serendipity_image_link" href="/uploads/Urlaub/2012-08-Berlin/Charlottenburg/P1020605.JPG" title="">
        <!-- s9ymdb:795 -->
        <img width="150" height="100" src="/uploads/Urlaub/2012-08-Berlin/Charlottenburg/P1020605.serendipityThumb.JPG">
      </a>
      </div>
      <div class="serendipity_imageComment_txt">P1020605</div>
  </div>
  <div class="serendipity_imageComment_left" style="width: 100px">
      <div class="serendipity_imageComment_img">
      <a rel="prettyPhoto" class="serendipity_image_link" href="/uploads/Urlaub/2012-08-Berlin/Charlottenburg/P1020606.JPG" title="">
        <!-- s9ymdb:795 -->
        <img width="100" height="150" src="/uploads/Urlaub/2012-08-Berlin/Charlottenburg/P1020606.serendipityThumb.JPG">
      </a>
      </div>
      <div class="serendipity_imageComment_txt">P1020606</div>
  </div>
  <div class="serendipity_imageComment_left" style="width: 150px">
      <div class="serendipity_imageComment_img">
      <a rel="prettyPhoto" class="serendipity_image_link" href="/uploads/Urlaub/2012-08-Berlin/Charlottenburg/P1020607.JPG" title="">
        <!-- s9ymdb:795 -->
        <img width="150" height="100" src="/uploads/Urlaub/2012-08-Berlin/Charlottenburg/P1020607.serendipityThumb.JPG">
      </a>
      </div>
      <div class="serendipity_imageComment_txt">P1020607</div>
  </div>
</div>
As you can see, something is running wild with height- and width-attributs on landscape-images.
bernd_d
Regular
Posts: 468
Joined: Thu Jun 03, 2010 9:28 am
Contact:

Re: [serendipity_event_imageselectorplus] wrong size for thu

Post by bernd_d »

Ok, i think i can specify the problem. It seems, the wrong output is only generated within entry-preview. Output after publishing looks good.
onli
Regular
Posts: 2825
Joined: Tue Sep 09, 2008 10:04 pm
Contact:

Re: [serendipity_event_imageselectorplus] wrong size for thu

Post by onli »

That is odd. Isn't the resizing done there on the same codepath and with the css of the template?
bernd_d
Regular
Posts: 468
Joined: Thu Jun 03, 2010 9:28 am
Contact:

Re: [serendipity_event_imageselectorplus] wrong size for thu

Post by bernd_d »

I'll try it tomorrow again, then we will see.
bernd_d
Regular
Posts: 468
Joined: Thu Jun 03, 2010 9:28 am
Contact:

Re: [serendipity_event_imageselectorplus] wrong size for thu

Post by bernd_d »

I think i got it...

Preview uses plugin_mediainsert.tpl from plugin-directory for generating the gallery-code but frontend-output (template 2k11) ignores this file.

Don't know if backend or template is going wrong in this case.
bernd_d
Regular
Posts: 468
Joined: Thu Jun 03, 2010 9:28 am
Contact:

Re: [serendipity_event_imageselectorplus] wrong size for thu

Post by bernd_d »

I'm getting crazy...now it is shown wrong in frontend too. :shock:

And yes...template_c and browser cache has been cleaned up before.

Seems, i have to run some tests again.
Don Chambers
Regular
Posts: 3652
Joined: Mon Feb 13, 2006 2:40 am
Location: Chicago, IL, USA
Contact:

Re: [serendipity_event_imageselectorplus] wrong size for thu

Post by Don Chambers »

bernd_d wrote:I'm getting crazy...now it is shown wrong in frontend too. :shock:
Looks fine to me. Have you cleared your browser's cache?
=Don=
bernd_d
Regular
Posts: 468
Joined: Thu Jun 03, 2010 9:28 am
Contact:

Re: [serendipity_event_imageselectorplus] wrong size for thu

Post by bernd_d »

Don Chambers wrote:Looks fine to me.
Really? For me, it looks like in following screenshot...
2012-11-07 07 23 08.jpg
2012-11-07 07 23 08.jpg (77.93 KiB) Viewed 6235 times
The images with red arrow are wrong. jpg-thumbnail has an height of 150px, but img-tag sets other sizes.
Don Chambers wrote:Have you cleared your browser's cache?
I can't count anymore, how often i did this ;)
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: [serendipity_event_imageselectorplus] wrong size for thu

Post by Timbalu »

This is landscape size.
The images will be automatically set to width: 150 in landscape and height: 150 in portrait size, IMHO.
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
bernd_d
Regular
Posts: 468
Joined: Thu Jun 03, 2010 9:28 am
Contact:

Re: [serendipity_event_imageselectorplus] wrong size for thu

Post by bernd_d »

I think, this is wrong. The img-tag should use the max-height-settings (all jpg-thumbs have an height of 150px). There is no reason for me, why landscape-images are resized to 100px instead of 150px.
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: [serendipity_event_imageselectorplus] wrong size for thu

Post by Timbalu »

I can't really answer to this, as I cannot dig into this further for lack of time.
But I had something congeneric in this thread http://board.s9y.org/viewtopic.php?f=10&t=18967
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
bernd_d
Regular
Posts: 468
Joined: Thu Jun 03, 2010 9:28 am
Contact:

Re: [serendipity_event_imageselectorplus] wrong size for thu

Post by bernd_d »

I have removed all height/wide-tags from tpl now. Works at the moment, don't know where the problem exactly is/was.
Post Reply