/    Sign up×
Community /Pin to ProfileBookmark

onLoad a link, as if it got clicked

Open [url]http://www.blizhosting.com/v4/index.php[/url] using Firefox, and use the Error console.

You’ll get the error:
Error: document.getElementById(“AutoLink”).click is not a function
Source File: [url]http://www.blizhosting.com/v4/coin_themes/Simple/scripts/lightbox.js[/url]
Line: 209

Basically, under the function, there’s only:
document.getElementById(“AutoLink”).click

How do I make it work….?

to post a comment
JavaScript

4 Comments(s)

Copy linkTweet thisAlerts:
@NedalsAug 16.2009 — Try 'onclick' not 'click'
Copy linkTweet thisAlerts:
@mingteikgauthorAug 17.2009 — Hmmm... After changing to "onclick", I get the following error in IE:

Webpage error details

User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; WOW64; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; MS-RTC LM 8)

Timestamp: Mon, 17 Aug 2009 01:28:44 UTC


Message: Object doesn't support this property or method

Line: 208

Char: 1

Code: 0

URI: http://www.blizhosting.com/v4/coin_themes/Simple/scripts/lightbox.js

Any idea?
Copy linkTweet thisAlerts:
@Sterling_IsfineAug 17.2009 — The click method is only supported by I.E.

Clicking that link on load would constitute a redirect, so you could just use:
[CODE]location.href="http://www.blizhosting.com/v4/coin_themes/Simple/intro_popup.html";[/CODE]
Copy linkTweet thisAlerts:
@mingteikgauthorAug 17.2009 — Hey,

thanks for your reply.

Actually I'm trying to implement:

http://particletree.com/features/lightbox-gone-wild/ , but I'm trying to have the pop up box to appear on page loads... Thus, i can't use 'href.location'...

Any other idea? ?
×

Success!

Help @mingteikg 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.27,
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,
)...