位置:首页 > 编程专栏 > JavaScript

js div 赋值

js div 赋值

<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title></title>
    <script>
        window.onload = function () {
            var show = document.getElementById('show');
            show.innerHTML = 'div赋值内容';
        }
    </script>
</head>
<body>
    <div id="show"></div>
</body>
</html>



C# 社区推荐