miniBB ® 

miniBB

®
Support Forums
  
 | Start | Register | Search | Statistics | File Bank | Manual |
Bugs miniBB Support Forums / Bugs /  
 

Attached Files — Image Viewer opening very large?

 
Author Steve Shaw
Partaker
#1 | Posted: 8 Oct 2021 13:54 
Hi Paul — I've just started to notice that when we attach images via 'Attach Files', they open in a really large new browser window, with a lot of white space, with the image in the top left corner.

Additionally, if you re-size the window, the image crops when the window is made smaller vertically, but the image compresses when the window is made smaller horizontally.

Is this as you expect?

Steve

Author Steve Shaw
Partaker
#2 | Posted: 8 Oct 2021 15:53 
Update — seems to be an issue with Chroma browser only?

Steve

Author Steve Shaw
Partaker
#3 | Posted: 8 Oct 2021 16:12 
(Sorry, should say the 'extra white space' is Chrome specific.
The re-size horizontal 'squeeze' issue is in other browsers too.

Steve

Author Paul
Lead Developer 
#4 | Posted: 9 Oct 2021 10:05 
At first, you may try to upload another file and check if the issue repeats? It could be related to just one specific file.

If it still repeats, I have to investigate it privately, as it could be related to a lot of specific conditions. You have my email address, so just drop a screenshot of your problem, and the files you're trying to upload, I'll take a look.

Author Steve Shaw
Partaker
#5 | Posted: 10 Oct 2021 18:46 
Hi Paul — the same happens on your 'demo forum'.

http://minibb.org/minibb-test.php?action=vthread&forum=1&topic=1989
Just click the image in Chrome.

oversize view

Steve

Author Paul
Lead Developer 
#6 | Posted: 10 Oct 2021 19:49 
Got it, thanks; let me take a look at it closer next week.

Author Paul
Lead Developer 
#7 | Posted: 18 Oct 2021 13:13 
I've checked this; alas the issue couldn't be fixed as it strictly depends on the browsers architecture which no script could control.

Obviously each browser has its own pre-defined minimum width of the pop-up window it could handle, this width is reserved for various browser tools and elements (such as window title, Minimize/Expand/Close buttons, address bar and its plugins and so on). In Opera it looks mostly the same:

Opera — handling the small image in pop-up

As soon as the content (image) width doesn't exceed this defined minimum, the space is added to handle the minimum.

To work-around this in a native way, you could edit addon_fileupload_options.php and make default values of a thumbnail larger, for example set them as:

$maxThWidth=300; //thumbnail width
$maxThHeight=300; //thumbnail height
also adjust the $autoGallery setting (set it to 3 or 2 by default, meaning how many pictures would fit in a row).

This will make images having smaller size not being opened in a pop-up, but straight visible on the page.

Author Steve Shaw
Partaker
#8 | Posted: 8 Nov 2021 10:00 
Sorry for the late reply, but the image size makes no difference...
Large images just open in HUGE browser windows, with a LOT of white surround.

Can you not use the same method as for 'Upload' files, where the images open in a new tab in the same browser window?

Steve

Author Paul
Lead Developer 
#9 | Posted: 8 Nov 2021 13:50 
Steve Shaw:
Large images just open in HUGE browser windows, with a LOT of white surround.
Could you make the screenshot of it? As I remember, something was coded that they should be scaled in proportion to the screen.

Steve Shaw:
Can you not use the same method as for 'Upload' files, where the images open in a new tab in the same browser window?
You could make it on your own, it's all customizable (just record this change in your notes so it's easy to restore in the case of upgrade). In bb_plugins.php code, for parseMessage function where it lists something like this:

$a1="<a href=\"{$a1_url}\" onclick=\"javascript:popUpFU({$post},{$if},'{$nameJs}',{$dataFile['image_width']},{$dataFile['image_height']},'{$altJs}',{$GLOBALS['topic']},'{$ext}'; ImgWin.focus(); return false;\" onmouseover=\"window.status='{$nameJs}';return true;\" onmouseout=\"window.status='';return true;\">";
you could just replace this code to:

$a1="<a href=\"{$a1_url}\" target=\"_blank\">";
I'm on the way of studying the synchronizing of this add-on with the Photoswipe library, so maybe in final it would give some better results...

Author Paul
Lead Developer 
#10 | Posted: 8 Nov 2021 18:57 
BTW I've tried to upload quite big picture in size (3005x2000 px) and on the screen which is 1280x1024 it scales quite well. Example:

Scaling 3005x2000 image on the 1280x1024 screen in popup

Tested in both Firefox and Edge on MS Windows 10 — what's the system you're experiencing this trouble?

Maybe you also could repeat this on the demo and drop me a screenshot...

Also, there's quite a common way of avoid this — you could uninstall the File Upload add-on and use just File Bank, this will simplify the things.

Author niamul21
Partaker
#11 | Posted: 20 Dec 2021 10:46 
Steve Shaw

I think there is an issue with chrome.

Bugs miniBB Support Forums / Bugs /
 Attached Files — Image Viewer opening very large?
 Share Topic's Link

Your Reply Click this icon to move up to the quoted message


  ?
Post as a Guest, leaving the Password field blank. You could also enter a Guest name, if it's not taken by a member yet. Sign-in and post at once, or just sign-in, bypassing the message's text.


Before posting, make sure your message is compliant with forum rules; otherwise it could be locked or removed with no explanation.

 

 
miniBB Support Forums Powered by Forum Software miniBB ® Home  Features  Requirements  Demo  Download  Showcase  Gallery of Arts
Compiler  Premium Extensions  Premium Support  License  Contact Us
Proceed with the Captcha add-on: protect your miniBB-forums from the automated spam and flood.


  ⇑