无法在我的网站上单击任何内容,在移动视图中
can't click anything on my website, in mobile view
Google 一直在修复我的 phone 后给我结果,但问题出在我的网站上。这是一个奇怪的问题,但是在我的网站上的移动设备上,我无法单击任何按钮或链接。台式机没问题,移动端出问题了。我是直接在cpanel上做这个网站的,所以我不知道是否需要添加一些特殊的代码来检测移动点击,我通常使用wordpress,所以我对直接做一个网站不是很了解在 mysqli 上。移动水龙头将在容器外工作,但我需要它在我的页面容器内工作。它在 <div>
和 <pre>
内。我不太明白这个问题,这是我的一些代码的样子:
全局样式:
pre{
border: solid 3px #2b333d;
border-radius: 10px;
font-size: 15px;
color: #3c3d3c;
margin: 1%;
padding: 10px;
background: #eaeaea;
display: block;
font-family: monospace;
white-space: pre-wrap;
}
input{
border: solid 2px #2b333d;
border-radius: 10px;
font-size: 15px;
color: #3c3d3c;
margin: 1%;
padding: 8px;
background: #f7f7f7;
font-family: Arial, Helvetica, sans-serif;
white-space: pre-wrap;
outline: none;
display: inline-block;
}
input[type=button], input[type=submit], input[type=reset]{
border: solid 2px #142135;
border-radius: 10px;
font-size: 18px;
color: #f7f7f7;
margin: 1%;
padding: 5px 7px;
background: #5791ed;
font-family: Arial, Helvetica, sans-serif;
white-space: pre-wrap;
outline: none;
letter-spacing: 0;
display: inline-block;
}
form{
line-height: 0.2;
white-space: normal;
}
Page/Header 样式:
.page_m{
background: #fcfcfc;
width: 99.9%;
left: 0.1%;
z-index: -20;
top: 30px;
position: relative;
}
.page_inner_m{
padding: 20px;
z-index: -20;
position: relative;
font-family: Arial, Helvetica, sans-serif;
white-space: pre-wrap;
color: #2d2d2d;
letter-spacing: 0.5;
line-height: 1.55;
border: 0;
border-radius: 0;
font-size: 18px;
margin: 0;
background: none;
display: block;
}
脚本:
<?php
?>
<style>
<?php include 'header.css'; ?>
</style>
<?php
echo '<div class="page_m">';
?>
<style>
<?phpinclude 'style_m.css';?>
</style>
<?php
echo '<pre class="page_inner_m">';
//header start
echo '<div class="menu_m">';
$host = $_SERVER['HTTP_HOST'];
preg_match("/[^\.\/]+\.[^\.\/]+$/", $host, $matches);
$domain = "{$matches[0]}\n";
echo '<center class="title_m">'.$domain.'</center>';
echo '</div>';
//header end
echo '</pre></div>';
echo '</div>';
?>
已修复 :D 只需将 echo '<pre class="page_inner_m">';
替换为 echo '<body class="page_inner_m">';
并将 echo '</pre></div>';
替换为 echo '</body></div>';
我会坚持下去,以防其他人觉得它有帮助。用 <body>
标签切换 <pre>
标签解决了我的问题。
Google 一直在修复我的 phone 后给我结果,但问题出在我的网站上。这是一个奇怪的问题,但是在我的网站上的移动设备上,我无法单击任何按钮或链接。台式机没问题,移动端出问题了。我是直接在cpanel上做这个网站的,所以我不知道是否需要添加一些特殊的代码来检测移动点击,我通常使用wordpress,所以我对直接做一个网站不是很了解在 mysqli 上。移动水龙头将在容器外工作,但我需要它在我的页面容器内工作。它在 <div>
和 <pre>
内。我不太明白这个问题,这是我的一些代码的样子:
全局样式:
pre{
border: solid 3px #2b333d;
border-radius: 10px;
font-size: 15px;
color: #3c3d3c;
margin: 1%;
padding: 10px;
background: #eaeaea;
display: block;
font-family: monospace;
white-space: pre-wrap;
}
input{
border: solid 2px #2b333d;
border-radius: 10px;
font-size: 15px;
color: #3c3d3c;
margin: 1%;
padding: 8px;
background: #f7f7f7;
font-family: Arial, Helvetica, sans-serif;
white-space: pre-wrap;
outline: none;
display: inline-block;
}
input[type=button], input[type=submit], input[type=reset]{
border: solid 2px #142135;
border-radius: 10px;
font-size: 18px;
color: #f7f7f7;
margin: 1%;
padding: 5px 7px;
background: #5791ed;
font-family: Arial, Helvetica, sans-serif;
white-space: pre-wrap;
outline: none;
letter-spacing: 0;
display: inline-block;
}
form{
line-height: 0.2;
white-space: normal;
}
Page/Header 样式:
.page_m{
background: #fcfcfc;
width: 99.9%;
left: 0.1%;
z-index: -20;
top: 30px;
position: relative;
}
.page_inner_m{
padding: 20px;
z-index: -20;
position: relative;
font-family: Arial, Helvetica, sans-serif;
white-space: pre-wrap;
color: #2d2d2d;
letter-spacing: 0.5;
line-height: 1.55;
border: 0;
border-radius: 0;
font-size: 18px;
margin: 0;
background: none;
display: block;
}
脚本:
<?php
?>
<style>
<?php include 'header.css'; ?>
</style>
<?php
echo '<div class="page_m">';
?>
<style>
<?phpinclude 'style_m.css';?>
</style>
<?php
echo '<pre class="page_inner_m">';
//header start
echo '<div class="menu_m">';
$host = $_SERVER['HTTP_HOST'];
preg_match("/[^\.\/]+\.[^\.\/]+$/", $host, $matches);
$domain = "{$matches[0]}\n";
echo '<center class="title_m">'.$domain.'</center>';
echo '</div>';
//header end
echo '</pre></div>';
echo '</div>';
?>
已修复 :D 只需将 echo '<pre class="page_inner_m">';
替换为 echo '<body class="page_inner_m">';
并将 echo '</pre></div>';
替换为 echo '</body></div>';
我会坚持下去,以防其他人觉得它有帮助。用 <body>
标签切换 <pre>
标签解决了我的问题。