Site Links
Home
Features
Documentation
Pricing & Order
Members Area
Support Options
UBBDev.com
UBBWiki.com
Who's Online Now
2 registered members (isaac, Gizmo), 85 guests, and 291 spiders.
Key: Admin, Global Mod, Mod
Member Spotlight
usrbingeek
usrbingeek
Burlington, VT
Posts: 115
Joined: June 2006
Show All Member Profiles 
Top Posters(30 Days)
Gizmo 23
Morgan 12
Ruben 8
SteveS 6
isaac 5
JAISP 2
Latest Photos
Test
Testing to drag photos
Comfortable Cats
Test
BSA photos
Previous Thread
Next Thread
Print Thread
Understanding Inline Attachments #261790
10/27/18 01:55 PM
10/27/18 01:55 PM
Baldeagle  Offline OP
Enthusiast
Joined: Oct 2007
Posts: 240
I'm trying to wrap my head around how the inline attachments work.

I'm going to describe what I think it means. Please correct me if I'm wrong.

Permissions/Forum/Max file attachment size determines the largest attachment allowed for upload

Attachments/Thumbnail Image Max Width/Height determines the max size of the inline thumbnails displayed at the bottom of a post

Attachments/Medium Image Max Width/Height determines the max size of the image displayed when you click on the inline images to view them

Attachments/Full Image Max Width/Height determines the max size of images stored in the attachment directory

Is my understanding correct? Or is the full-size image stored on the hard drive and only resized for viewing?


The Stovebolt Geek
http://www.stovebolt.com/ubbthreads/ubbthreads.php

UBBThreads 7.6.1.1
Web Server Apache/2.4.29
PHP Version 5.6.32
MySQL Version 5.5.58-log
Database Size 2.04 GB
Express Hosting
Express Hosting "We are the official hosting company of UBB.threads. Ask us about our free migration services to migrate your UBB.threads installation."
Re: Understanding Inline Attachments [Re: Baldeagle] #261792
10/27/18 02:05 PM
10/27/18 02:05 PM
Gizmo  Online Tapedshut
UBB.threads Developer
Joined: Jun 2006
Posts: 17,002
Portland, OR; USA
The responsive page display takes priority over any image dimensions as a smart fallback; so mobile users can see a huge image on their tiny screens (otherwise they'd be bombarded by something that'd require them to scroll).

The images are processed with the compression settings you setup via the attachments settings; allowing an 8MB upload will allow a user to upload a huge image, that'll be compressed down.

The thumb max height/width affects the display of the thumbnail, medium I don't believe is used anymore, full is the max size the image can be stored as on the server.

If you look at the image information of my attached image you'll see that its scaled to 200x200 (thumb width) as a 30.73KB image (it was 49KB, so it was compressed); since the image was only 600x600 it didn't reach the full size max dimensions, so it retains the dimensions of the original.

Attached Files 3019770961872192759.jpg

I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Need to Upgrade?
Forums: A Gardeners Forum Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Re: Understanding Inline Attachments [Re: Baldeagle] #261793
10/27/18 02:11 PM
10/27/18 02:11 PM
Baldeagle  Offline OP
Enthusiast
Joined: Oct 2007
Posts: 240
OK. So, if we allow 5MB uploads, the size of the file stored in the attachments directory is determined by the setting we use for Attachments/Full Image Max Width/Height?

What determines the size of the images you view when you click on an inline array of images?


The Stovebolt Geek
http://www.stovebolt.com/ubbthreads/ubbthreads.php

UBBThreads 7.6.1.1
Web Server Apache/2.4.29
PHP Version 5.6.32
MySQL Version 5.5.58-log
Database Size 2.04 GB
Re: Understanding Inline Attachments [Re: Baldeagle] #261794
10/27/18 02:17 PM
10/27/18 02:17 PM
Gizmo  Online Tapedshut
UBB.threads Developer
Joined: Jun 2006
Posts: 17,002
Portland, OR; USA
If you allow 8MB-12MB uploads (which I recommend, since it's about the highest I've seen from cellphones), you'll end up with images around 400k-700k (depending on compression and full size dimension). They'll be resized to the full size dimensions only if the image exceeds that dimension (I allow 1920 as the max).

The FILESIZE is determined based on the image dimensions and the compression; it'll vary by image, especially using an image with a lot of detail.

When you click on an image and it opens in the lightbox, or you display inline, it should display the image with the css "max-width: 100%;"; which means as wide as the screen allows before trying to stretch the page.

Attached Image:
Original: 7,147 KB, 3036x4048
Parsed: 673 KB, 1440x1920

Compression level for full images: 60%

Attached Files IMG_20181020_143838.jpg

I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Need to Upgrade?
Forums: A Gardeners Forum Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Re: Understanding Inline Attachments [Re: Baldeagle] #261795
10/27/18 02:22 PM
10/27/18 02:22 PM
Baldeagle  Offline OP
Enthusiast
Joined: Oct 2007
Posts: 240
Thanks. That's the clarification I needed.


The Stovebolt Geek
http://www.stovebolt.com/ubbthreads/ubbthreads.php

UBBThreads 7.6.1.1
Web Server Apache/2.4.29
PHP Version 5.6.32
MySQL Version 5.5.58-log
Database Size 2.04 GB
Re: Understanding Inline Attachments [Re: Baldeagle] #261796
10/27/18 02:25 PM
10/27/18 02:25 PM
Gizmo  Online Tapedshut
UBB.threads Developer
Joined: Jun 2006
Posts: 17,002
Portland, OR; USA
I just uploaded an image from this last weekends camping trip; I chose it because of the level of detail, to show an example of compression on a large image.


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Need to Upgrade?
Forums: A Gardeners Forum Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Re: Understanding Inline Attachments [Re: Baldeagle] #261798
10/29/18 01:52 PM
10/29/18 01:52 PM
Baldeagle  Offline OP
Enthusiast
Joined: Oct 2007
Posts: 240
I've been doing some testing, and I have some questions.

I uploaded a 3.8 MB image as an attachment. Instead of being displayed inline, it displayed as a link. On the hard drive, it was 2.2MB, which is 60% of its original size, so the compression is working as expected. But I *thought* that the file's size would be reduced to 650 pixels (the setting we have in attachments), and it was not.

When I deleted the post, the attachment was deleted as well, although its record was retained in the database.

What am I missing?


The Stovebolt Geek
http://www.stovebolt.com/ubbthreads/ubbthreads.php

UBBThreads 7.6.1.1
Web Server Apache/2.4.29
PHP Version 5.6.32
MySQL Version 5.5.58-log
Database Size 2.04 GB
Re: Understanding Inline Attachments [Re: Baldeagle] #261799
10/29/18 02:18 PM
10/29/18 02:18 PM
Gizmo  Online Tapedshut
UBB.threads Developer
Joined: Jun 2006
Posts: 17,002
Portland, OR; USA
The end filesize depends on the image quality you allow (defaults are thumb 200, medium 480, full 1920) and the max dimension you allow (if an image doesn't meet the dimension it will not be resized; the defaults are thumb 80%, medium 70%, full 60%), the level of detail the image has, and the Image Library you're utilizing to process images.

ImageMagick will process images more efficiently, and will more aggressively compress images; the downside is that it doesn't come pre-bundled with PHP like GD (it has to be installed to the local filesystem). Your host likely has it installed, you just have to populate the paths in the UBB.threads "Paths" configuration. I believe there was previously an issue with IM processing image dimensions (the system was rewritten in v7.6.2, whereas the following link is a patch for v7.6.1.1), that discussion can be found here.

The "Max File Size for Displaying Attached Images Inline" setting in the Attachments Settings will allow you to limit the images being displayed to the browser based on how large the image is; I wouldn't have this setting much higher than about a meg as your mobile users will have some pretty large images to push through their data plan.


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Need to Upgrade?
Forums: A Gardeners Forum Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Re: Understanding Inline Attachments [Re: Gizmo] #261800
10/29/18 03:51 PM
10/29/18 03:51 PM
Baldeagle  Offline OP
Enthusiast
Joined: Oct 2007
Posts: 240
I have ImageMagick installed and enabled. I read the referenced post and edited the image.inc.php file, and uploads/attachments now work as expected. Thanks for your help.


The Stovebolt Geek
http://www.stovebolt.com/ubbthreads/ubbthreads.php

UBBThreads 7.6.1.1
Web Server Apache/2.4.29
PHP Version 5.6.32
MySQL Version 5.5.58-log
Database Size 2.04 GB

Shout Box
Today's Birthdays
No Birthdays
Recent Topics
Reddy Kilowatt
by SteveS. 11/20/18 08:30 AM
testar
by Morgan. 11/18/18 02:33 PM
Phishing SCAM emails
by Morgan. 11/16/18 01:28 PM
Repliers can change thread title
by Baldeagle. 11/12/18 08:49 PM
Tabs In Header
by AstroCat. 11/11/18 08:33 AM
Forum Statistics
Forums36
Topics35,168
Posts191,613
Members12,114
Most Online978
Jun 24th, 2007
Random Image
Powered by UBB.threads™ PHP Forum Software 7.6.2