WEB开发网
开发学院图形图像Flash Silverlight(27) - 2.0网页之可脚本化, 与DOM的交... 阅读

Silverlight(27) - 2.0网页之可脚本化, 与DOM的交互, 与JavaScript的交互

 2009-02-16 11:57:05 来源:WEB开发网   
核心提示: DOMDemo.html<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional

DOMDemo.html

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
  <title>Silverlight20</title>
  <style type="text/css">
    html, body
    {}{
      height: 100%;
      overflow: auto;
    }
    body
    {}{
      padding: 0;
      margin: 0;
    }
    #silverlightControlHost
    {}{
      height: 100%;
    }
  </style>
  
  <script type="text/javascript" src="../Silverlight.js"></script>
  
</head>
<body>
  <!--由 Silverlight 控制此 id 为 hello 的 DOM-->
  <div style="font-size: 12px; display: none" id="hello">
  </div>
  <div style="font-size: 12px">
    加载 Silverlight20.WebPage.DOMDemo 后,测试 Silverlight 和页面 DOM 的交互</div>
  <div id="silverlightControlHost">
    <object id="xaml1" data="data:application/x-silverlight-2," type="application/x-silverlight-2"
      width="100%" height="100%">
      <param name="source" value="../ClientBin/Silverlight20.xap" />
      <param name="EnableHtmlAccess" value="true" />
    </object>
    <iframe style='visibility: hidden; height: 0; width: 0; border: 0px'></iframe>
  </div>
</body>
</html>

上一页  1 2 3 4 5 6 7  下一页

Tags:Silverlight 网页 脚本

编辑录入:爽爽 [复制链接] [打 印]
赞助商链接