/    Sign up×
Community /Pin to ProfileBookmark

Scroll iFrame contents to the right upon load

Hi I’m searching for a script to shift (scroll) the contents of an iFrame 50 pixels towards the right upon loading.

In a nutshell the iFrame will be loading a 200x50px picture, the iFrame is only 150px wide with it’s scrollbars disabled and I would like the pic to be showing it’s right side (scrolled 50px to the right upon load).

Here’s how far I got (I know it’s not much)

<iframe src=”http://www.mysite.com/weatherBox.htm” align=”right” frameborder=”0″ marginwidth=”1″ marginheight=”0″ scrolling=”No” width=”150″ height=”50″ ></iframe>

I thought align=”right” would do the trick but didn’t work

If anybody knows of a good tut or a code snippet that could help, I would greatly appreciate anything.

Thanks in advance.

Diego.-

to post a comment
JavaScript

1 Comments(s)

Copy linkTweet thisAlerts:
@mrhooMar 19.2008 — Make the iframe full size but put it in a div that clips the display the way you want it.

You can't scoll if you disabled scrolling...
×

Success!

Help @upiorz 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 6.17,
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: @nearjob,
tipped: article
amount: 1000 SATS,

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

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,
)...