如何删除超链接文本的下划线 [英] How to remove the underline of hyperlink text
本文介绍了如何删除超链接文本的下划线的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想知道如何删除超链接文本的下划线。下面是我的代码:
< asp:HyperLink ID = HyperLink1 NavigateUrl = 〜/ registration.aspx runat = server < span class =code-attribute>
< span class =code-attribute> 风格 = z-指数:1;上:173px;位置:绝对;身高:26px;宽度:110px; left:1081px; > 新注册< / asp:HyperLink >
在新注册下方,必须删除屏幕上显示的下划线。
可以提供任何建议。
问候。
解决方案
在你的样式表中处理它。添加以下内容
# HyperLink1
{
text-decoration : 无;
}
这将从您的超链接中删除此特定ID的下划线
将CssClass属性添加到超链接
< asp:HyperLink ID = HyperLink1 NavigateUrl = 〜/ registration.aspx runat = server CssClass = hyp > 新注册< / asp:HyperLink >
< pre lang =xml> < style 类型 = text / css >
.hyp
{
text-decoration:none;
z-index:1;
top:173px;
仓位:绝对;
身高:26px;
宽度:110px;剩余
:1081px;
}
< / style >
您可以在< asp:HyperLink>中添加它。也是这样的:
< asp:HyperLink ID =HyperLink1runat =serverFont-Underline =false />
希望它有所帮助。
I would like to know how to remove the underline of a hyperlink text. Hereunder is my code:
<asp:HyperLink ID="HyperLink1" NavigateUrl="~/registration.aspx" runat="server"
style="z-index: 1; top: 173px; position: absolute; height: 26px; width: 110px; left: 1081px;">New registration</asp:HyperLink>
Beneath ''New registration'' the underline that appears on the screen has to be removed.
Can any one advice.
Regards.
解决方案
Handle it in your style sheet. Add the following
#HyperLink1 { text-decoration: none; }
This will remove the underline from your hyper link for this specific ID
Add CssClass property to hyperlink
<asp:HyperLink ID="HyperLink1" NavigateUrl="~/registration.aspx" runat="server" CssClass="hyp">New registration</asp:HyperLink>
<style type="text/css"> .hyp { text-decoration:none; z-index: 1; top: 173px; position: absolute; height: 26px; width: 110px; left: 1081px; } </style>
You can add this in the <asp:HyperLink> too, something like this:
<asp:HyperLink ID="HyperLink1" runat="server" Font-Underline="false" />
Hope it helps.
这篇关于如何删除超链接文本的下划线的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文