/    Sign up×
Community /Pin to ProfileBookmark

scrolling past banner ads

I’m trying to bypass angelfire.com’s ugly site-design-killing banner ad, by automatically scrolling past it, giving the illusion that it’s not there (sure, you could still scroll up and see it, but at least the page would look right when it loaded…)

Anyway, I’ve been trying variations of…

<script language=”javascript” type=”text/javascript”>
window.location=”#top”
</script>

…using the anchor point #top set just past the ad, at the real top of my page. It’s working fine as a link, when I link to index.html#top, but I can’t get it to load automatically. The code above should work as a redirect as soon as the page loads, but it’s not… do I need some kind of onLoad command, or does Angelfire have something blocking this script from working properly?

Andy Oliphant
The Thirteenth Hour

to post a comment
JavaScript

1 Comments(s)

Copy linkTweet thisAlerts:
@SamAug 28.2003 — <i>
</i>&lt;script type="text/javascript&gt;
function scrollMe()
{
window.location='#top';
}
&lt;/script&gt;
&lt;body onload="scrollMe()"&gt;

That should do it for ya
×

Success!

Help @metallibanger 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.6,
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,
)...