I have the following HTML code, using Bootstrap:
<div class="progress">
<div class="progress-bar progress-bar-striped active" id="progress-bar" role="progressbar" aria-valuenow="0" aria-valuemin="0" aria-valuemax="100" style="width: 0%;">
</div>
</div>
我希望style="width: 0"
能够增加到100%。我尝试使用下面的代码进行测试,但是没有任何反应。
<head>
<title>Verifying Oracle database...</title>
<script src="ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
<link rel="stylesheet" type="text/css" href="bootstrap/css/bootstrap.min.css">
<script type="text/javascript" src="bootstrap/js/bootstrap.min.js"></script>
<script>
$(document).ready(function() {
$("#progress-bar").css("width", "50%");
$("#progress-bar").attr("aria-valuenow", "50%");
});
</script>
</head>
有人能帮助推动这个进程吗?
提前感谢。
$(document).ready()
中或将脚本放置在<body>
的末尾。 - Brennan<body>
的末尾,但还是不起作用。:( - Lucas Rezende