Riešenie
8. Objekty
1.
<html>
<head>
<title>Okno</title>
<script language="JavaScript">
function maleokno(text)
{
male=window.open("","maleokno","directories=no,menubar=no,width=250,height=150");
male.document.write("<html><body><h1>maleokno</h1>" + text + "<br></body></html>");
}
</script>
</head>
<body>
<form>
<input type="button" value="okno otvoriť"
onclick="maleokno('Malé ale dobré!')"><br><br>
<input type="button" value=" okno zatvoriť" onclick="male.close()"><br>
</form>
</body>
</html>
2.
<html>
<head><title>2oknar</title>
<script language="JavaScript">
F1=window.open("okno.htm","okno1","width=300,height=200,screenX=0,screenY=0");
F2=window.open("okno.htm","okno2","width=400,height=100,screenX=300,screenY=300");
</script>
</head>
<body>
</body>
</html>
späť
|