如果不使用jQuery,我将如何实现此功能?
...
<noscript>
<div style="left:0; right: 0; top: 40px; bottom: 0; position: absolute; text-align: center; vertical-align: middle">
<span class="alert alert-info">This page requires JavaScript to be enabled to work.</span>
</div>
</noscript>
...
<div id="application" style="display: none" ng-controller="MyController" >
....Application HTML...
</div>
...
<script>
$('#application').show()
</script>
答案 0 :(得分:3)
您可以使用
中的纯CSS使用样式隐藏application
div
<noscript>
<style>
#application { display: none; }
<style>
</noscript>
答案 1 :(得分:0)
喜欢这个......
// $('#application').show()
document.getElementById('application').style.display = "block"