Html Css超链接字体颜色不变
我看到过类似的帖子。我修改了代码,目前正在使用此代码为超链接文本添加颜色。Html Css超链接字体颜色不变,html,css,hyperlink,Html,Css,Hyperlink,我看到过类似的帖子。我修改了代码,目前正在使用此代码为超链接文本添加颜色。我的超链接在运行时在HTML输出中生成。我有多个css。我认为css效果正在覆盖 a:link { color: red; color: inherit; text-decoration:underline; } 我也试过这个: a:link { color: #fff; text-decoration:underline; } 我的剧本: function (response) {
我的超链接在运行时在HTML输出中生成。
我有多个css。我认为css效果正在覆盖
a:link
{
color: red;
color: inherit;
text-decoration:underline;
}
我也试过这个:
a:link
{
color: #fff;
text-decoration:underline;
}
我的剧本:
function (response) {
obj =response.d;
var output = "<table class='table'><tr><th>Serial No.</th><th>UFZillaID</th><th>MZillaID</th><th>Status</th></tr>";
for (var x = 0; x < obj.length; x++) {
output += "<tr><td >" + obj[x].EMID + "</td></tr>";
}
output += "</table>";
$("#result").append(output);
函数(响应){
obj=响应d;
var output=“序列号UFZillaIDMZillaIDStatus”;
对于(变量x=0;x
这是我的标记
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="UFZillaErrorStatus.aspx.cs"
Inherits="Dashboard.Web.UFZillaErrorStatus" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title>UFZillaErrorStatus</title>
<link href="http://fonts.googleapis.com/css?family=Open+Sans:400,300,600,700,800|Open+Sans+Condensed:300,700"
rel="stylesheet" />
<link href="css/home.css" rel="stylesheet" type="text/css" media="all" />
<link href="css/themes/ui-lightness/jquery-ui-1.10.1.custom.css" rel="stylesheet"
type="text/css" />
<link href="css/assets/style.css" rel="stylesheet" type="text/css" />
<link href="js/common/jquery.jqGrid-4.5.4/css/ui.jqgrid.css" rel="stylesheet" type="text/css" />
<script src="js/common/jquery.jqGrid-4.5.4/js/jquery-1.9.0.min.js" type="text/javascript"></script>
<script src="js/common/jquery/json2.js" type="text/javascript"></script>
<script src="js/common/jquery/jquery-ui-1.10.1.custom.min.js" type="text/javascript"></script>
<script src="js/common/jquery.jqGrid-4.5.4/js/i18n/grid.locale-en.js" type="text/javascript"></script>
<script src="js/common/jquery.jqGrid-4.5.4/js/jquery.jqGrid.min.js" type="text/javascript"></script>
<script src="js/common/jquery.jqGrid-4.5.4/plugins/grid.postext.js" type="text/javascript"></script>
<script src="js/JqueryFileupload/jquery.fileupload.js" type="text/javascript"></script>
<script src="js/JqueryFileupload/jquery.iframe-transport.js" type="text/javascript"></script>
<script src="js/common/jquery/jquery.alphanumeric.js" type="text/javascript"></script>
<script src="js/dashboard/UFZillaErrorStatus.js" type="text/javascript"></script>
<script type="text/javascript">
$(document).ready(function () {
});
</script>
</head>
<body>
<form id="form1" runat="server">
<div class="content1" style="background: 0 0 0 #FFFFF">
<div id="uferrdivs" align="center">
<table>
<tr>
<td>
Product
</td>
</tr>
<tr>
<td>
<select id="proselct">
</select>
</td>
</tr>
</table>
<center>
<div>
<div id="result" style="background-color: #F5F5F5; width: 800px; margin-top: 50px;">
</div>
</div>
</center>
</div>
</div>
</form>
</body>
</html>
Ufzilla错误状态
$(文档).ready(函数(){
});
产品
…下划线效果出现..但颜色不变..我尝试了其他方法。但不起作用
任何建议都会有帮助删除:
color: inherit;
因为这将覆盖您想要的颜色。确保您的标签包含
href="#"
至少。尝试最简单的方法
使用这个css
a, a * {
color: #FFF !important; // important will avoid if any other css try to override it
}
如果背景颜色为白色,则链接将不可见。因为您为链接设置了相同的颜色 颜色:#FFF 尝试使用不同的颜色尝试删除
color: inherit;
看看它会起作用
两者的简单演示
使用继承
不使用inherit你想应用什么颜色?白色?你能创建一个提琴来测试吗?页面的背景色是什么?如果是白色,链接将不可见。我也尝试了红色。它不起作用…我编辑了我的代码你是否应用了其他css类来链接?