Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

need to use the IF statement

Status
Not open for further replies.

needhelpfast

Programmer
Mar 28, 2002
3
0
0
CA
Hey,

I was wondering if you could help me on a script. For my website I made an alert pop up and im not sure how to use a IF statement properly. I want the person to click ok and then the screen to shake and then for it to start to scroll down automatically.

If you can help me, that would be great.

P.S. I already have the scipts for all those... need to know how to put it all together

Thx,

Bijan
 
from what i can tell, you don't really need an if statement. Below is how I would do it. where the names 'screenShake' and 'pageScroll' should be changed to whatever the names of those functions are.

function go() {
alert("whatever");
screenShake();
}
function screenShake() {
// ..code
pageScroll();
}
function pageScroll() {
// ..code
}

and in the <body> tag, type in onload=&quot;go();&quot;

btw, for if statements, see
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top