使用bootstrap框架建立modal对话框,对话框并不能够正常显示
<!DOCTYPEhtml><html><headlang="en"><metacharset="UTF-8"><metaname="viewport"content="...
<!DOCTYPE html>
<html>
<head lang="en">
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width;intital-scale=1" >
<meta http-equiv="x-ua-compatible" content="IE=edge">
<title></title>
<link href="bootstrap.css" rel="stylesheet">
</head>
<body>
<div class="container">
<div class="modal fade">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
<h4 class="modal-title">Modal title</h4>
</div>
<div class="modal-body">
<p>One fine body…</p>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
<button type="button" class="btn btn-primary">Save changes</button>
</div>
</div><!-- /.modal-content -->
</div><!-- /.modal-dialog -->
</div><!-- /.modal -->
</div>
<script src="jquery-2.1.1.js"></script>
<script src="bootstrap.js"></script>
</body>
</html> 展开
<html>
<head lang="en">
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width;intital-scale=1" >
<meta http-equiv="x-ua-compatible" content="IE=edge">
<title></title>
<link href="bootstrap.css" rel="stylesheet">
</head>
<body>
<div class="container">
<div class="modal fade">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
<h4 class="modal-title">Modal title</h4>
</div>
<div class="modal-body">
<p>One fine body…</p>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
<button type="button" class="btn btn-primary">Save changes</button>
</div>
</div><!-- /.modal-content -->
</div><!-- /.modal-dialog -->
</div><!-- /.modal -->
</div>
<script src="jquery-2.1.1.js"></script>
<script src="bootstrap.js"></script>
</body>
</html> 展开
1个回答
2015-04-08 · 知道合伙人互联网行家
关注
展开全部
<!doctype html>
<html lang="zh-cn">
<head>
<link rel="shortcut icon" href="../img/logo_title.ico">
<meta charset="UTF-8" http-equiv="X-UA-Compatible" content="IE=Edge">
<link rel="stylesheet" href="../ex/bootstrap.min.css">
<title>Welcome to credIT!</title>
</head>
<body id="home">
<div class="container">
<div class="btn-toolbar">
<div class="pull-right">
<a href="#login" data-toggle="modal" class="btn">登陆</a>
<a href="../php/register.php" class="btn">注册</a>
</div>
</div>
</div>
<div class="container">
<div class="modal" id="login" aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-head">
<a href="#" class="close" data-dismiss="modal">×</a>
<h4>用户登陆</h4>
</div>
<div class="modal-body">
<form class="form-horizontal">
<div class="control-group">
<label class="control-label" name="username">用户名</label>
<div class="controls">
<input type="text">
</div>
</div>
<div class="control-group">
<label class="control-label" name="password">密码</label>
<div class="controls">
<input type="text">
</div>
</div>
</form>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-primary">登陆</button>
</div>
</div>
</div>
</div>
</div>
<script src="../ex/jquery.js"></script>
<script src="../ex/bootstrap.min.js"></script>
</body>
</html>
<html lang="zh-cn">
<head>
<link rel="shortcut icon" href="../img/logo_title.ico">
<meta charset="UTF-8" http-equiv="X-UA-Compatible" content="IE=Edge">
<link rel="stylesheet" href="../ex/bootstrap.min.css">
<title>Welcome to credIT!</title>
</head>
<body id="home">
<div class="container">
<div class="btn-toolbar">
<div class="pull-right">
<a href="#login" data-toggle="modal" class="btn">登陆</a>
<a href="../php/register.php" class="btn">注册</a>
</div>
</div>
</div>
<div class="container">
<div class="modal" id="login" aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-head">
<a href="#" class="close" data-dismiss="modal">×</a>
<h4>用户登陆</h4>
</div>
<div class="modal-body">
<form class="form-horizontal">
<div class="control-group">
<label class="control-label" name="username">用户名</label>
<div class="controls">
<input type="text">
</div>
</div>
<div class="control-group">
<label class="control-label" name="password">密码</label>
<div class="controls">
<input type="text">
</div>
</div>
</form>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-primary">登陆</button>
</div>
</div>
</div>
</div>
</div>
<script src="../ex/jquery.js"></script>
<script src="../ex/bootstrap.min.js"></script>
</body>
</html>
追问
没用啊!还是不能显示!我在chrome和ie11上都试过,不显示!
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询