1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Image size clarification

Discussion in 'XenForo Questions and Support' started by Don, Oct 15, 2010.

  1. Don

    Don Member

    OK, I understand about the max size and max file size settings. Mine are set to 900X900 and max of 2048Mb. When I upload a .jpg file, I often see, "Click on image to view full size", but nothing happens when I do that. I was thinking that if I allow a large file to be uploaded, the normal post view would display a 900X900 size, but clicking on it could enlarge it to its actual size of 1024X768 or some such. Am I misunderstanding this?

    I tried changing the size setting to zero, then uploaded a large photo. Predictably, it displayed in it's full size... way too big for most screens.

    Apparently, the resizing takes place during the upload process. So what is the purpose of the popup that allows full size viewing? :confused:

    I'm happy with the way it's working now. I just think I might be missing something.
     
  2. Mythotical

    Mythotical Well-Known Member

    You got it right about how the images would work when clicking on the view full image.

    From my understanding the resizing during upload is only a thumbnail alteration. Are you clicking the "Add to Post" option? If not then give that a try if so I would double check your settings for images in posts. You might have missed something.
     
  3. Brogan

    Brogan XenForo Moderator Staff Member

    As I understand it, the image size restrictions will resize any uploaded image to those maximum dimensions (retaining the ratio).

    So if you have them set to 1600x1200 for example, that will be the largest image size displayed.

    If however your style has a fixed width of e.g. 980px then the image will be dynamically resized to fit within the post body.

    Clicking it will expand it to full size of 1600x1200.

    The message to click on an image to view full size when it is already full size is a known bug.

    The image attached here is 1920x1200 and I have embedded it and left it as a thumbnail.
    As you can see, the limits which are set here resize it to 1280x800.
    If you select the Fixed Width Style you will see how it fits in the post body but expands when clicked.

    scrat.jpg

    scrat.jpg
     
    Jake Bunce likes this.
  4. DSF

    DSF Well-Known Member

    @Brogan
    Your explanation is correct :)
     
  5. wwwicked

    wwwicked Active Member

  6. Don

    Don Member

    Ahhh, something just clicked. I remember seeing this function work on my laptop, but couldn't replicate it on the iMac 24" screen... duh! The screen resolution is 1920X1200 so naturally, everything is going to display at the max expanded limit all the time.

    I knew I was missing something. You jogged my brain and a lightbulb came on. Thanks for the responses. Long Live XenForo! :)
     
  7. Rich

    Rich Active Member

    I may be wrong but wouldn't it be nice to have the software resize the photo as other softwares do and then the photo wont fail to upload and have a resizing issue for the end user
     
  8. Brogan

    Brogan XenForo Moderator Staff Member

    Server-side file size (KB) resizing is not supported. Any files which are larger than the maximum size specified in the ACP -> Options -> Attachments: Maximum Attachment File Size (KB) will be rejected.

    However, uploaded files are first resized based on the maximum physical dimensions (pixels) set in the ACP -> Options -> Attachments: Maximum Attachment Image Dimensions. If the resized image is below the maximum file size (KB) limit, then it will be allowed.

    In reality, that means I can comfortably upload 6MB images to my site, which has a maximum file size of 1024KB and maximum dimensions of 1440x960 set in the ACP.
     
  9. Rich

    Rich Active Member

    Its me Im sorry / so then the large file still sits on the server? or is it being resized and what would be settings so that the user is not inconvenienced by resizing.
     
  10. Brogan

    Brogan XenForo Moderator Staff Member

    There are always 2 versions of every image stored on the server - the large version (whether resized or not) and the thumbnail.

    If you don't want images to be resized, set Attachments -> Maximum Attachment Image Dimensions to 0.

    You will however have to increase Attachments -> Maximum Attachment File Size (KB) to the largest file size which you expect your members to upload.
    For some modern cameras that could mean extremely large file sizes of up to 10MB.
     
  11. Rich

    Rich Active Member

    thank you , your settings seem to work well thanks!
     
  12. Can I just confirm, that means if I set max size as 900 x 900 and file size of 250kb, then someone uploads a 2000 x 2000 file that's 2mb, the image will auto resize to fit within my settings - and that resized version is what ends up in my database and is viewable on the forum, and not the original 2mb file?
     
  13. Brogan

    Brogan XenForo Moderator Staff Member

    I'll post this from the FAQ, as that explains it.

    Why can't I upload an image, even though it is smaller than the maximum dimensions (pixels) permitted?
    Server-side file size (KB) resizing is not supported. Any files which are larger than the maximum size specified in the ACP -> Options -> Attachments: Maximum Attachment File Size (KB) will be rejected.


    Why can I upload an image, even though it is larger than the maximum file size (KB) permitted?
    Uploaded files are first resized based on the maximum physical dimensions (pixels) set in the ACP -> Options -> Attachments: Maximum Attachment Image Dimensions. If the resized image is below the maximum file size (KB) limit, then it will be allowed.

    http://xenforo.com/community/threads/frequently-asked-questions.5183/#post-180445
     
  14. Great, thank you Brogan, appreciated. When I read the FAQ before it was for something else so I somehow skipped that. I had visions of loads of huge files being stored on the server!

    Thanks again :)
     

Share This Page