/    Sign up×
Community /Pin to ProfileBookmark

Loading images in an iframe, image loads weird with different browsers.

So on this page [url]www.japst4r.net/art.html[/url] I have this really simple html setup (because that is all that I am capable of) so that when a user clicks on the banner thumnails near the bottom, they load in the banner area above the thumbnails. It works fine in my browser (Safari) but in other browsers such as IE and Firefox it gets all funky. Here are some examples of how the image load differently in different browsers:

Here it is in Safari, everything loads fine.
[URL=http://img314.imageshack.us/img314/5517/safari9xk.png][IMG]http://img314.imageshack.us/img314/5517/safari9xk.th.png[/IMG][/URL]

Here it is in IE, for some reason the images loads either off set or too small or something (I can’t tell for sure cause this is just a screen cap a friend provided me, I don’t have IE to mess with cause I’m on a Mac) but as you can see it forces the iframe to have scrollbars. Very weird.
[URL=http://img336.imageshack.us/img336/3893/ie8ps.png][IMG]http://img336.imageshack.us/img336/3893/ie8ps.th.png[/IMG][/URL]

And here we are in Firefox. For some reason the image decides to load way too small so you have all that extra space in the iframe.
[URL=http://img336.imageshack.us/img336/6444/firefox2sr.png][IMG]http://img336.imageshack.us/img336/6444/firefox2sr.th.png[/IMG][/URL]

Ok so my main quesions are:

1.) Is there a way to just force the image to load the way I want it? I have the iframes dimensions set to be the same as the image, so I don’t see why it wouldn’t just match up.

2.) Should I just dump the iframe altogether, and if so what is another way I could get the images to load up there? Can I set a name to a table cell and then target it from the image link? I thought I had read somewhere that iframes weren’t recommended or weren’t supported in some browsers or something, but I’m a total newb so I could be way off.

Any advice would be much appreciated. Thanks in advance.

[b]Edit:[/b] Also, are you guys able to see the thumbnails in my post? Or are they just showing up as direct links? I have my options set to show images, and the links I used in my post show up as thumbnails on another forum that I tested them on just now, so I’m not sure what is going on.

to post a comment
HTML

4 Comments(s)

Copy linkTweet thisAlerts:
@ray326Jul 23.2005 — Using overflow:hidden on the iframe may get you a little farther along. If you ditch the iframe you'll have to replace some of the functionality with Javascript. Frying pan to fire scenario.
Copy linkTweet thisAlerts:
@japst4rauthorJul 23.2005 — ^^^^

I'm not very experienced with html, how might that be implemented? I did some googling to come up with adding this in the tag [i]style="overflow:hidden;width:800px;height:110px;"[/i] and I tried it and it didn't seem to make a difference in Firefox. Still works in Safari though.
Copy linkTweet thisAlerts:
@ray326Jul 23.2005 — That was in the iframe tag? Worked for me as embedded rather than inline.

iframe { overflow:hidden }

The result was the elimination of the scrollbars.
Copy linkTweet thisAlerts:
@japst4rauthorJul 24.2005 — ^^^

Thanks I'll give it a shot.
×

Success!

Help @japst4r spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.28,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...