Java-applet tag konverteret til Object - hvordan dyn størrelse ?
Hejsa.....Jeg har en applet jeg vil vise i min browser..... men størrelsen på appletten skal være afhængig af størrelsen på ens vindue....
følgende kode virker ikke...... Applet'en startes men er kun 0x0 pixels stor..... og det virker jo ikke så godt....
60 gode point til den person der kan levere noget funktionsdygtig kode jeg kan Copy'n'Paste direkte.....
Kode:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<script language="JavaScript" type="text/javascript">
<!--
function adjustWindow()
{ window.toolbar.visible = false;
window.menubar.visible = false;
window.locationbar.visible = false;
window.moveTo(0,0);
window.resizeTo(screen.width, screen.height);
}
//-->
</script>
</head>
<body onLoad="adjustWindow">
<center>
<script language="JavaScript" type="text/javascript">
<!--
var width = window.innerWidth;
var height = window.innerHeight;
//-->
</script>
<!-- HTML CONVERTER //-->
<OBJECT
classid = "clsid:CAFEEFAC-0014-0002-0000-ABCDEFFEDCBA"
codebase = "http://java.sun.com/products/plugin/autodl/jinstall-1_4_2-windows-i586.cab#Version=1,4,2,0"
WIDTH = "java script:width;" HEIGHT = "java script:height;" >
<PARAM NAME = CODE VALUE = "administration.presentation.Desktop" >
<PARAM NAME = "type" VALUE = "application/x-java-applet;jpi-version=1.4.2">
<PARAM NAME = "scriptable" VALUE = "false">
<COMMENT>
<EMBED
type = "application/x-java-applet;jpi-version=1.4.2" \
CODE = "administration.presentation.Desktop" \
WIDTH = "java script:getAppletWidth();" \
HEIGHT = "java script:getAppletHeight();" \
scriptable = false \
pluginspage = "http://java.sun.com/products/plugin/index.html#download">
<NOEMBED>
<h1>Sorry, your browser isn't capable of showing Java Applets</h1>
</NOEMBED>
</EMBED>
</COMMENT>
</OBJECT>
<!--
<APPLET CODE = "administration.presentation.Desktop" WIDTH = "java script:getAppletWidth();" HEIGHT = "java script:getAppletHeight();">
<h1>Sorry, your browser isn't capable of showing Java Applets</h1>
</APPLET>
-->
<!--"END_CONVERTED_APPLET"-->
</center>
</body>
</html>
