gpt4 book ai didi

javascript - Bootstrap 在计算机浏览器上工作,但在移动浏览器上不起作用

转载 作者:太空宇宙 更新时间:2023-11-03 20:30:02 24 4
gpt4 key购买 nike

我为我的网站使用 Bootstrap ,切换按钮在计算机浏览器上有效,但在移动浏览器上无效

这是代码:

 <meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="css/bootstrap.min.css">
<link rel="stylesheet" href="css/styles.css">
<link rel="stylesheet" href="css/bootstrap-multiselect.css">
<link href="css/bootstrap-select.min.css" rel="stylesheet" />
<link href="https://code.jquery.com/ui/1.12.0/themes/smoothness/jquery-ui.css" rel="stylesheet"/>
<link rel="stylesheet" href="https://rawgit.com/trentrichardson/jQuery-Timepicker-Addon/master/dist/jquery-ui-timepicker-addon.min.css">
<link href="css/lightbox.css" rel="stylesheet" />
<link rel="shortcut icon" type="image/x-icon" href="img/favicon.ico" />

<nav class="navbar navbar-default">
<div class="container-fluid">
<div class="navbar-header">
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar4">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="main.php"><img src="img/t-square-logo-Final.png" alt="T-square" class="tslogo"/></a>
</div>
<div id="navbar4" class="navbar-collapse collapse">
<ul class="nav navbar-nav">
<li class="active"><a href="main.php">Home</a></li>
<li><a href="dms.php">DMS</a></li>
<li><a href="main.php?action=backup">Backup</a></li>
<li><a href="logout.php">LogOut</a></li>
</ul>
</div>
</div>
</nav>

<link rel="stylesheet" href="css/bootstrap.min.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
<script src="js/bootstrap.min.js"></script>

我试着做 here但是我还是有同样的问题

谁能帮我解决问题??

最佳答案

将此添加到标题

<meta name="viewport" content="width=device-width, initial-scale=1">

关于javascript - Bootstrap 在计算机浏览器上工作,但在移动浏览器上不起作用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/44158241/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com