Javascript examples for DOM HTML Element:Object
Object width Property - Change the height and width of an <object> element to 300px:
<!DOCTYPE html> <html> <body> <object id="myObject" width="250" height="200" data="helloworld.swf" style="border:1px solid black"></object> <button onclick="myFunction()">Test</button> <p id="demo"></p> <script> function myFunction() {/*from ww w . j a v a 2 s. c om*/ document.getElementById("myObject").height = "500"; document.getElementById("myObject").width = "500"; } </script> </body> </html>