Images in posts overlap to the right.

Started by catfished, February 10, 2010, 02:01:42 PM

Previous topic - Next topic

catfished

Version: 2.0.RC2
When viewing large images in posts that are linked from other sites using the [img] tag, they overlap onto the right column.

This might be a Simple Portal 2.3.1 problem as I'm using it for the right column but I thought I'd ask here first. Thanks for any replies.
You use and like this forum software? Then show your appreciation and support by becoming a Charter Member.



CatfishEd.com

JimM

Are those photos larger than your set max image size? 
Jim "JimM" Moore
Former Support Specialist

catfished

Quote from: JimM on February 10, 2010, 08:32:56 PM
Are those photos larger than your set max image size?

Thanks for your reply JimM. No they are not. I have a couple of SMF 1.1.11 forums also using Simple Portal 2.3.1 and they handle similar images with a side scroll bar:


You use and like this forum software? Then show your appreciation and support by becoming a Charter Member.



CatfishEd.com

JimM

Are the forums that add the scroll bar on the same host as the one that doesn't?  Do any of them have additional mods that might affect the displaying of images?
Jim "JimM" Moore
Former Support Specialist

catfished

Quote from: JimM on February 11, 2010, 07:47:33 PM
Are the forums that add the scroll bar on the same host as the one that doesn't?  Do any of them have additional mods that might affect the displaying of images?

All forums are on my server but just in case you missed it, the ones with the scroll bar are version 1.1.11 while the overlap one is RC2, all are using Simple Portal 2.3.1.

No mods on any of them that affect images. Here's one of the 1.1.11 ones mod list:
1.      Member Color Link       1.8.7        [ List Files ]  [ Delete ]
2.     SimplePortal     2.1.1     [ List Files ] [ Delete ]
3.     SMF 1.1.1 Update Package     1.1.1     [ List Files ] [ Delete ]
4.     SMF 1.0.16 / 1.1.8 Update     1.0     [ List Files ] [ Delete ]
5.     SMF 1.0.17 / 1.1.9 / 2.0 RC1 Update     1.0     [ List Files ] [ Delete ]
6.     Signature Option Post     1.1     [ Apply Mod ] [ List Files ] [ Delete ]
7.     SMF 1.0.13 / 1.1.5 / 2.0 b3.1 Update     1.0     [ List Files ] [ Delete ]
8.     SMF 1.0.19 / 1.1.11 Update     1.0     [ Uninstall ] [ List Files ] [ Delete ]
9.     SMF 1.0.14 / 1.1.6 Update     1.0     [ List Files ] [ Delete ]
10.     YouTube BBC Tag (XHTML Compliant)     1.0     [ Uninstall ] [ List Files ] [ Delete ]
11.     SMF 1.0.18 / 1.1.10 / 2.0 RC1-2 Update     1.0     [ List Files ] [ Delete ]
12.     SMF 1.1.2 Update Package     1.1.2     [ List Files ] [ Delete ]
13.     SMF 1.0.18 / 1.1.10 / 2.0 RC1-2 Update     1.1     [ List Files ] [ Delete ]
14.     EzPortal     0.3.4     [ Apply Mod ] [ List Files ] [ Delete ]
15.     OS & Browser Detection     1.4     [ Uninstall ] [ List Files ] [ Delete ]
16.     Users Online Today Mod     1.3.1     [ Uninstall ] [ List Files ] [ Delete ]
17.     MessagePreviewOnHover     1.4     [ Uninstall ] [ List Files ] [ Delete ]
18.     SMF 1.0.11 / 1.1.3 Update     1.1     [ List Files ] [ Delete ]
19.     SMF 1.0.18 / 1.1.10 / 2.0 RC1-2 Update     1.0     [ List Files ] [ Delete ]
20.     SMF 1.0.15 / 1.1.7 Update     1.0     [ List Files ] [ Delete ]
21.     SimplePortal     2.3.1     [ Uninstall ] [ List Files ] [ Delete ]
22.     Ad Managment     2.3     [ Uninstall ] [ List Files ] [ Delete ]
23.     Stop Spammer     2.2     [ Uninstall ] [ List Files ] [ Delete ]
24.     SMF 1.0.12 / 1.1.4 / 2.0 b1.1 Update     1.0     [ List Files ] [ Delete ]
25.     SMF 1.1.2 Update Package     1.1.2     [ List Files ] [ Delete ]
26.     SMF Links     1.6.3     [ List Files ] [ Delete ]

And the RC2 with the overlap problem:
1.      Last Active On MemberList       1.02        [ Uninstall ]  [ List Files ]  [ Delete ]
2.     Stop Spammer     2.3.6     [ Uninstall ] [ List Files ] [ Delete ]
3.     Users Online Today     1.5.5     [ Uninstall ] [ List Files ] [ Delete ]
4.     MessagePreviewOnHover     1.7     [ Uninstall ] [ List Files ] [ Delete ]
5.     Add IP2Location to Track IP     1.3     [ Uninstall ] [ List Files ] [ Delete ]
6.     SimplePortal     2.3.1     [ Uninstall ] [ List Files ] [ Delete ]
You use and like this forum software? Then show your appreciation and support by becoming a Charter Member.



CatfishEd.com

JimM

Interesting.  It might be worth posting at http://simpleportal.net/ to see if they have run into this before.  Did you have this forum running on RC1.2 with the same issue or did it just start occurring on RC2?
Jim "JimM" Moore
Former Support Specialist

catfished

Quote from: JimM on February 12, 2010, 06:56:56 PM
Interesting.  It might be worth posting at http://simpleportal.net/ to see if they have run into this before.  Did you have this forum running on RC1.2 with the same issue or did it just start occurring on RC2?

I converted it from MyBB to version 1.1.11 and immediately upgraded to RC2. It didn't start until the upgrade to RC2 but I really didn't check it until the final upgrade.

It's just a small forum for a kid that needs a fishing forum for his friends: http://carpinusa.com/forum/
You use and like this forum software? Then show your appreciation and support by becoming a Charter Member.



CatfishEd.com

JimM

I looked through the bugtracker for problems with images on RC2 because I suspected you were going to say that it didn't start till upgrading.  I suggested asking at SimplePortal because there may have been an issue with Curve that they are aware of.
Jim "JimM" Moore
Former Support Specialist

catfished

Quote from: JimM on February 13, 2010, 11:41:22 AM
I looked through the bugtracker for problems with images on RC2 because I suspected you were going to say that it didn't start till upgrading.  I suggested asking at SimplePortal because there may have been an issue with Curve that they are aware of.

Thanks JimM, I'll do that.
You use and like this forum software? Then show your appreciation and support by becoming a Charter Member.



CatfishEd.com

catfished

I scanned through the posts on SP and did a search there but no useful results.
You use and like this forum software? Then show your appreciation and support by becoming a Charter Member.



CatfishEd.com

swoodie

see if this resolves your issue it did mine http://simpleportal.net/index.php?topic=3731.0 last post

I think it's because your attachment thumbnails are quite large to fit in that block.

./Sources/PortalBlocks.php


Code: (Find) [Select]
$item['file']['image']['link']

Code: (Replace) [Select]
str_replace('<img', '<img width="100"', $item['file']['image']['link'])
You can change 100 in the code as you like. It's in pixels.

the fish in my avatar are australian sea Bream

catfished

Quote from: swoodie on February 15, 2010, 08:29:01 PM
see if this resolves your issue it did mine http://simpleportal.net/index.php?topic=3731.0 last post

I think it's because your attachment thumbnails are quite large to fit in that block.

./Sources/PortalBlocks.php


Code: (Find) [Select]
$item['file']['image']['link']

Code: (Replace) [Select]
str_replace('<img', '<img width="100"', $item['file']['image']['link'])
You can change 100 in the code as you like. It's in pixels.

the fish in my avatar are australian sea Bream

Thanks for your reply but the link to the thread (which I read when I searched SP's site before) and the code changes you provided, are referring to images in Simple Portal blocks which I'm not having any problems with. Mine are images in posts that are posted via links from Image Shack, Photo Bucket, etc. By the way, I have limited the size of posted images in Admin CP but it has no effect. Oh, and I don't have it set to use thumbnails but that would only effect attached images anyway.

I'm normally using Firefox so that's what I was using for the screenshots but I have since discovered that there is a side scroll bar for large images when viewing in IE 7. It still looks terrible in IE but at least they can see the right block. If there was a way to limit the size of posted images, linked images, not attachments,   it would solve my problem.
You use and like this forum software? Then show your appreciation and support by becoming a Charter Member.



CatfishEd.com

catfished

Anyone else have any ideas on how to fix this?
You use and like this forum software? Then show your appreciation and support by becoming a Charter Member.



CatfishEd.com

catfished

You use and like this forum software? Then show your appreciation and support by becoming a Charter Member.



CatfishEd.com

Kays

If you want the scroll bars to appear, in index.css  change the oveflow for .post and .inner to scroll.

Code (change the overfow) Select

.post, .personalmessage
{
overflow: scroll;
line-height: 1.4em;
padding: 0.1em 0;
}


Code (add the overflow) Select

.inner
{
padding: 1em 1em 0 0;
margin: 0 1em 0 0;
border-top: solid 1px #99a;
overflow: scroll;
}

If at first you don't succeed, use a bigger hammer. If that fails, read the manual.
My Mods

catfished

Quote from: Kays on February 18, 2010, 01:06:54 AM
If you want the scroll bars to appear, in index.css  change the oveflow for .post and .inner to scroll.


Thanks Kay, I don't have time to try it now but I will do so later. It seems strange that it already scrolls in IE but not in Firefox but I guess it makes sense to you coders. :)
You use and like this forum software? Then show your appreciation and support by becoming a Charter Member.



CatfishEd.com

Kays

I don't understand it either since changing it in .post will affect one browser and in .inner another browser.

If at first you don't succeed, use a bigger hammer. If that fails, read the manual.
My Mods

catfished

OK, I edited the index.css file in the default theme (only one that's used) and now the horizontal scroll bar shows up so at least there's no overlap. Thanks for providing a fix.

I am curious as to why there can't be a way to limit the size of posted images to prevent this in the first place. I understand that we can limit the size of attached images but evidently there's no way to control the size of linked images from Image Shack, Photo Bucket, etc. I know it can be done on IPB so hopefully SMF will have it soon. Thanks again Kay.
You use and like this forum software? Then show your appreciation and support by becoming a Charter Member.



CatfishEd.com

Kays

Glad that did it. :)

There is a setting under Features and Options to set the max size of posted images.

If at first you don't succeed, use a bigger hammer. If that fails, read the manual.
My Mods

catfished

#19
Quote from: Kays on February 19, 2010, 12:07:50 AM
Glad that did it. :)

There is a setting under Features and Options to set the max size of posted images.

Yeah, I had tried that but it didn't work. I tried it again now and it works for new posts but the old ones still overlap, plus the scroll bar doesn't work in Linux Ubuntu so I'm back to the overlap. Of course, since 99.9999% of his visitors will be using Windoze, it doesn't matter anyway. :)

Edit: Actually, the scroll bar does show up in a browser called Epiphany in Ubuntu but not good old Ubuntu Firefox. This is hilarious, I suppose we could add another line of CSS code to make it work but it's totally unnecessary. I'm only posting this because it's comical at this point.

Once again, thanks a bunch for all your help.
You use and like this forum software? Then show your appreciation and support by becoming a Charter Member.



CatfishEd.com

Advertisement: