html 超链接在某些设备上无法正常工作

标签 html css

我在两段中有两个超链接。它们都适用于我的手机,只有第二个适用于我的笔记本电脑,没有一个适用于我的 iPad。

<div class="about-me">
  <p>Kevin (Quito [Key'-tow]) Williams is an aspiring front-end web designer.
     He has 5 years of experience in HTML, 4 years experience in CSS, and is
     currently studying jQuery. As a modern web designer, he is using his
     coding background to study the latest web technologies: HTML5, CSS3, <a target="_blank" href="https://en.wikipedia.org/wiki/Responsive_web_design">RWD</a>.
     In addition to his web technology languages, he also has experience in:
     C<sup>++</sup>, Javascript, Java, Perl, Lua (Minecraft based), LISP, SQL.
  </p>
  <p>During his 5<sup><sup>1</sup>/<sub>2</sub></sup> years of <a target="_blank" href="http://www.wau.edu">college</a>, he took many computer
     science classes in his pursuit of his current Bachelor of Science
     Degree in Mathematics. Near the end of his studies, he took an
     interest in Web Development, and decided to pursue it as a career.
     He is trying to start his career as a freelancer, at least until he
     lands the job he wants.
  </p>
</div><!-- /about-me -->


.about-me a {
  font-size: 2em;
  background: #ff9500; /* For browsers that do not support gradients */
  background: -webkit-linear-gradient(white, #ff9500); /* For Safari 5.1 to 6.0 */
  background: -o-linear-gradient(white, #ff9500); /* For Opera 11.1 to 12.0 */
  background: -moz-linear-gradient(white, #ff9500); /* For Firefox 3.6 to 15 */
  background: linear-gradient(white, #ff9500); /* Standard syntax */
  color: black;
  box-shadow: 0 8px 12px 0 rgba(255,255,255,0.6);
  padding: 10px;
}

.about-me a {
  font-size: 1em;
  text-decoration: none;
  padding: 0;
}

anchor CSS 被拆分,因为第二个 anchor 与其他一些元素具有相同的 CSS。

我的 HTML 中的正文具有 ontouchstart 属性。知道为什么会这样吗?我有影响链接的 CSS,但这只是美学;没有什么可以阻止任何事情发生。

最佳答案

您是否有任何可能导致问题的 Javascript 代码?很奇怪<a></a>标签不起作用,它们在所有浏览器中都是标准的。

关于html 超链接在某些设备上无法正常工作,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/44665899/

相关文章:

javascript - 避免两次包含js文件的方法

css - 获取 CSS calc 的结果以设置自定义属性

javascript - 向下滚动时替换固定图像,然后将其更改为相对图像

HTML "bring to front"未使用 z-index

css - 当 li 悬停时显示另一个 div

javascript - safari 中 float 元素父容器的宽度

javascript - 离线网页 javascript sleep() 或 wait() 函数

javascript - 将 Canvas 用于游戏的真正好处是什么?

html - 覆盖嵌套类的 CSS 宽度

javascript - 可以重置而不重叠的计时器? - JavaScript