SimplePortal

Support => English Support => Topic started by: nugget on April 25, 2010, 04:39:56 PM

Title: Latest image block
Post by: nugget on April 25, 2010, 04:39:56 PM
POWERED BY SMF 2.0 RC2 | SMF © 2006–2009, SIMPLE MACHINES LLC
SIMPLEPORTAL 2.3.1 © 2008-2009, SIMPLEPORTAL FLAGRANT_ALT BY CRIP



When I add the 'Recent Image Attatchments' block (left side) the images are displayed full size with scroll bars.
I have left block set to 180 in config

It doesn't do this for 'Gallery' - they show the right size.

Can you tell me what I am doing wrong?

Thank you.
Title: Re: Latest image block
Post by: AngelinaBelle on April 27, 2010, 10:37:20 AM
Can you give a link?
Title: Re: Latest image block
Post by: nugget on April 27, 2010, 03:43:10 PM
The forum is: www.nuggetfishing.com.au/smf (http://www.nuggetfishing.com.au/smf)

But I do not have the recent images block enabled because of the error.

Is nobody else having this problem?
Then maybe it is a setting I have wrong - probably in SMF not SP?
Title: Re: Latest image block
Post by: AngelinaBelle on April 27, 2010, 08:33:20 PM
Perhaps you can try a SimplePortal page, and only enable the block on that test page, so you can show the problem?
Title: Re: Latest image block
Post by: nugget on April 29, 2010, 06:55:54 PM
Sorry I don't know how to do that.

I have attached a screen shot of the problem - bottom of the left column
Title: Re: Latest image block
Post by: Old Fossil on April 29, 2010, 07:52:37 PM
Have you tried resizing the images?

Also I would advise you upgrade to the latest version ie 1.1.11 and SP 2.3.2
Title: Re: Latest image block
Post by: nugget on April 30, 2010, 08:06:43 PM
It is my understanding the purpose of the block is to display images from posts.
I can not control the image size uploaded by members - I can restrict the max size ect but not control what they upload.
Are you suggesting I resize every image?
I thought that was the purpose of the max width setting in SP config?

Please explain what you mean.
Thank you
Title: Re: Latest image block
Post by: Old Fossil on April 30, 2010, 08:14:06 PM
When I want to include an image I use a programme which resizes images so they fit in the blocks otherwise the blocks will have scrollbars.

I keep all my images in my photobucket account.

Title: Re: Latest image block
Post by: nugget on May 01, 2010, 02:17:51 PM
So how does that relate to images in posts?
That will work for an individual's images you upload but not for pulling images from posts within a forum.
You ask all members to use this program?

The purpose of the block is to display a 'thumbnail' of images in posts.
Surly SP resizes them to suite the column size as set up in config.

Sorry but I can't see how your solution works in a active forum.
Title: Re: Latest image block
Post by: Old Fossil on May 01, 2010, 04:39:20 PM
I see your point.
Title: Re: Latest image block
Post by: nugget on May 01, 2010, 06:16:06 PM
Can anybody help with this problem?

Thanks
Title: Re: Latest image block
Post by: AngelinaBelle on May 03, 2010, 09:29:20 AM
May I please see an example of the problem?
I don't want to give you a wrong answer.
 
Have you ever created a custom page in SimplePortal?
Once you create a custom page, you can find that block in the block list and use the "Advanced Display Options" to show it only on the new custom page.
 
Then, nobody will see that custom page unless you give them the link.
 
Could you try that?
Title: Re: Latest image block
Post by: Mooshoe on May 03, 2010, 09:31:49 PM
I am also having this same issue.

Example: http://www.amisharmy.com/index.php

All of the images pulled are too big, and make scrollbars in the block.
Title: Re: Latest image block
Post by: AngelinaBelle on May 04, 2010, 10:36:32 AM
Is it possible to see a page that demonstrates the problem?
 
Title: Re: Latest image block
Post by: Mooshoe on May 04, 2010, 09:34:45 PM
http://www.amisharmy.com/index.php?page=test1
Title: Re: Latest image block
Post by: AngelinaBelle on May 05, 2010, 11:24:04 AM
mooshoe -- As guest, I see no images.
nugget -- can you go to SimplePortal>pages and create a new page, then go to the blocks list make the latest image block show up on the new page?
 
 
Title: Re: Latest image block
Post by: nugget on May 06, 2010, 03:51:08 AM
I created a page, added the recent images block but can't see it anywhere - sorry I have never used the page option so do not know how to use it.
I've just enabled the recent images block it on my forum again to show you but just realised because you're a guest, you can't see images.

Can I create a user name and PW for you? - PM if that suits better.

PS - I thought the screen shot I posted earlier would be enough?
Title: Re: Latest image block
Post by: AngelinaBelle on May 06, 2010, 08:38:57 AM
I was hoping to look at the page HTML and CSS using IE8's "developer tools". To see what was going on.
 
To make a block appear on a page and not on the portal, check the "advanced display actions" box, then expand the "Pages" list, and check the box next to the page you want that block to appear on.  Make sure the block is active, and you should see it the next time you load that page.
 
Title: Re: Latest image block
Post by: nugget on May 06, 2010, 03:01:51 PM
I'm using SP in 'integration' mode.
I have created a new page and made it visible (green tick).
I have set the recent images block to show on that page (in advanced option)
But I can not see where the page appears - I can't see it anywhere or a link to it.
The SP admin calls it Page202
Title: Re: Latest image block
Post by: AngelinaBelle on May 06, 2010, 03:15:48 PM
Here are the ways to see your pages:
1) Go to the list of pages. Click on the name of your page. You will see your page and the URL will be in the adress bar of your browser.
2) If you know it is called Page202, then it will be at ?page=Page202.  But I looked at http://www.nuggetfishing.com.au/smf/indes.php?page=Page202 (http://www.nuggetfishing.com.au/smf/indes.php?page=Page202), and also at  http://www.nuggetfishing.com.au/smf/indes.php?page=page202 (http://www.nuggetfishing.com.au/smf/indes.php?page=page202), but I did not see anything.
Title: Re: Latest image block
Post by: nugget on May 06, 2010, 03:23:33 PM
OK - did that

I think it should be at:
http://www.nuggetfishing.com.au/smf/index.php?page=page202

Title: Re: Latest image block
Post by: nugget on May 06, 2010, 03:24:52 PM
Oh dam - you're still not going to see them because you're not logged in - how do I get around that?
Title: Re: Latest image block
Post by: AngelinaBelle on May 06, 2010, 04:17:20 PM
If you wish, you may permit me to register, or create a temporary test account.
 
Title: Re: Latest image block
Post by: AngelinaBelle on May 06, 2010, 04:57:41 PM
That "Latest Images" block shows up on the main page.
I did not run across the custom page you mention.
That image is really big.  And simpleportal does not resize it.
 
I will ask for more information from those who know more.
Title: Re: Latest image block
Post by: nugget on May 06, 2010, 05:02:37 PM
Yes I have set the recent images block to show but as you said - the image is too big so it put scroll bars in.
I will leave the test account and the recent image block there for the time being - thank you for your help.

Title: Re: Latest image block
Post by: AngelinaBelle on May 11, 2010, 02:11:39 PM
I'm sorry to leave you hanging.  I have now posted a question to the devs about this.
Title: Re: Latest image block
Post by: nugget on May 11, 2010, 04:36:28 PM
Thank you - Look forward to a resolution.
Cheers
Title: Re: Latest image block
Post by: AngelinaBelle on May 13, 2010, 02:13:08 PM
I don't have an answer to your question, and the development team is short-staffed at the moment. They trying to squeeze in some time for SimplePortal on top of their other responsibilities.
 
I think the short answer is: you will generally have that problem if the image is too large for the block.
The long answer will have to do with some customization, and possibly a feature request.
 
One of the beta testers suggested replacing the function, in PortalBlocks, with one that would use thumbnails instead of the full-size image.  He did suggest some code, but nobody has had time to test it.
 
Title: Re: Latest image block
Post by: nugget on May 14, 2010, 01:11:26 AM
I was given a solution by a member of my forum who has SP on another forum.
He found it here buried somewhere.

PortalBlocks.php
Code: (Find)
', $item['file']['image']['link'], '

Code: (Replace)
<a href="' . $item['topic']['href'] . '">', str_replace('<img', '<img width="100"', $item['file']['image']['thumb']), '</a>

Worked for my forum.

Thanks


Title: Re: Latest image block
Post by: swoodie on May 14, 2010, 05:54:44 AM
glad it worked for you nugget, you owe me lol, kidding i got the info from here


Hi thanks for your help i resolved the issue i used this
<a href="' . $item['topic']['href'] . '">', str_replace('<img', '<img width="100"', $item['file']['image']['thumb']), '</a>

from topic http://simpleportal.net/index.php?topic=4118.msg30022#msg30022   post#31
so the image would still link to the post with no scroll bars on image

same issue as i had i think a few people have this problem
Title: Re: Latest image block
Post by: AngelinaBelle on May 14, 2010, 07:18:29 AM
Yep.  That's the general idea. Use the thumbnail and set the width.
 
SimplePortal 2.3.8 © 2008-2024, SimplePortal