Professional Documents
Culture Documents
Practicle 11 Client Side Scripting
Practicle 11 Client Side Scripting
<html>
<head>
function openWindow()
window.open(",""", "left=0,top=0,width=200,height=100");
</script>
</head>
<body>
</body>
</html>
Output:
Window close():
<html>
<head>
var new_win;
function openWindow()
new_win=window.open("","","width=200,height=100");
function closeWindow()
new_win.close();
</script>
</head>
<body>
</body>
</html>
Output:
scrollTo To ():
<html>
<head>
function scrollWindow()
scrollTo(0,1);
}
</script>
</head>
<body>
<p> sayali</p>
<p>.........window is Scrolled</p>
</body>
</html>
Output:
ScrollBy ():
<html>
<head>
function scrollWindow()
{
scrollTo(0,100);
</script>
</head>
<body>
<p> a </p>
<p> b </p>
<p> c </p>
<p> d </p>
<p>.........window is Scrolled</p>
</body>
</html>
Output:
setTimeout ():
<html>
<head>
function myfunction()
setTimeout(displayfunction,5000);
function displayfunction()
alert("time out");
</script>
</head>
<body>
</body>
</html>
Output: