• Welcome to Tux Reports: Where Penguins Fly. We hope you find the topics varied, interesting, and worthy of your time. Please become a member and join in the discussions.

Under Consideration Featured Image Is A Square

Laron

Young Flying Bird
XenWord Professional
Please complete the following information. You may add or remove any questions you feel will help clarify your specific situation.

WordPress version:4.6.1
XenForo version: 1.5.10
XenWord version: 3.4

What WordPress plugins do you have active?

What happens when these WordPress plugins are not active?

What WordPress theme are you using?
Newspaper

To the best of your abilities please describe the specific problem you are experiencing:

The image that appears automatically in a new Xenforo thread, based on an article (page) being posted in wordpress, is a square, and should be the original size of the image.

Example, this is what is posted in the thread.

example 3.jpg


But this is what it should be.

example 1.jpg

So the image is being squashed into a square and this looks bad on the thread preview of the post.

This is my current setting.

example 2.jpg


I have had to modify that so that the large wordpress featured image is displayed, but the large image is too big. Ideally I would like a size that is in-between the large one and the smaller one but that is not a big deal, the problem is the image is the wrong resolution/size from being a square and not showing as original.

This is a low priority issue for me.

How can this be repeated ?
Yes
Have you looked at the PHP code ?
No
Please do not submit a bug report if you have not actually verified this is a bug. Instead, please use the support forums or open a ticket for help.
 

Laron

Young Flying Bird
XenWord Professional
(In reference to you moving my thread from the bug board) I would personally call this a bug, rather than a suggestion, as the image is not being displayed correctly.
 

Gracie

Dogs Times Writer
It's working as designed, therefore not a bug. Code can be changed to add and change features. For example, this is moved here so that @LPH can look at ways to add options for different sizes. Here is the current code:

Code:
/**
* Option to show a large featured image rather than a thumbnail
*
* @since 3.0.0.07
*/
if ( $xenword_options['use_large_featured_image'] == true ) {
   $featured_image = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), 'large' );
} else {
   $featured_image = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), 'thumbnail' );
}

Size names are: ‘thumb’, ‘thumbnail’, ‘medium’, ‘large’, ‘post-thumbnail’

https://developer.wordpress.org/reference/functions/add_image_size/

You'll also see on the page that there is a custom_image option that will require rewriting code in this area. In other words, the current behavior is as designed and not a bug. I'm sure LPH is aware of this request and will try to rework it. He's very serious about requests and doesn't take any of them lightly.

I do recall the first time featured image request was made, added, then others requested options for thumbnails and large versus medium.

I'd probably recommend a pull down of options for the five size names instead of an on/off for large versus thumbnail.
 

Laron

Young Flying Bird
XenWord Professional
When looking at the example images I included, I just realised that the image is not squashed, but cropped. For some reason I was seeing it as being squashed down into a perfect square and loosing it's format. I can understand that it is not a bug because of this.

I wasn't looking at asking for a size change, just to make sure the image was nor pushed in from the sides and loosing it's resolution/format.
 
  • Like
Reactions: LPH
Top