链接下划线没有下划线如何? [英] link underline and no underline how to?

查看:140
本文介绍了链接下划线没有下划线如何?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们正在处理的网站有一些锚点链接,你点击它们就可以了。

滚动到页面底部,回答问题

链接在...上。无论如何要做到这一点,以便当页面加载时,链接不是
下划线,当用户将鼠标移动到

时,它会加下划线,鼠标输出没有强调。我试过了:


< a href ="#section14" class =" drkblue08bold"

style =" text-decoration:none">


但这使得下划线永远消失了,那里的课程是只为

颜色,颜色不需要改变,


也试过:


< a HREF ="#section14" class =" drkblue08bold"

style =" text-decoration:none"

onmouseover =" this.style.textDecoration =''none'';"

onmouseout =" this.style.textDecoration =''none'';">


但是这样做没有下划线所有时间,即使鼠标

超过文本。


也试过


< a href = "#section14" class =" drkblue08bold"

onmouseover =" this.style.textDecoration =''none'';"

onmouseout =" this.style.textDecoration = ''没有';">


但是当页面加载时,就行了。


你可以看到我也没有使用样式表来做这件事,因为

在网站上做风格的主要人员已经有一段时间了,所以我们

想要尽量避免弄乱这项工作,是否可以这样做

没有上面的样式表,或者需要样式表可以

有人展示如何做到这一点。

the site we''re working on has some anchor links, you click them they
scroll to the bottom of the page with the answers to the questions
linked on to. is there anyway to make it so that the links are not
underlined when the page loads, when the user moves the mouse over
it''s underlined, mouse out no underline. i tried:

<a href="#section14" class="drkblue08bold"
style="text-decoration:none">

but that left the underline gone forever, the class there is just for
color, color does not change no need to,

also tried:

<a href="#section14" class="drkblue08bold"
style="text-decoration:none"
onmouseover="this.style.textDecoration =''none'';"
onmouseout="this.style.textDecoration=''none'';">

but this made it so there was no underline all the time, even if mouse
was over the text.

also tried

<a href="#section14" class="drkblue08bold"
onmouseover="this.style.textDecoration =''none'';"
onmouseout="this.style.textDecoration=''none'';">

but with this the line is there when the page loads.

as you can see i''m also not using style sheets to do this, because the
main person who does the styles on the site is out for a while, so we
want to try to avoid messing with this work, is it possible to do this
without style sheets like above, or is style sheets are needed can
someone show how to do it.

推荐答案

jmaxsherkimer在10/09/2004 23:53说了以下内容:
jmaxsherkimer said the following on 10/09/2004 23:53:
无论如何都有当页面加载时,当用户将鼠标移动到下划线时,鼠标悬停没有下划线,以使链接不加下划线。


是的,但我怀疑这是不是一件好事,因为大多数用户都希望

链接加下划线(appart for menu''或者其他一些特殊用途。

i尝试过:

< a href =" #section14" class =" drkblue08bold"
style =" text-decoration:none">

但是下划线永远消失了,这个类只有
颜色,颜色不变不需要,


按预期工作。

也试过:

< a href =" ;#section14" class =" drkblue08bold"
style =" text-decoration:none"
onmouseover =" this.style.textDecoration =''none'';"
onmouseout =" this.style.textDecoration =''none'';">

但这使得它一直没有下划线,即使鼠标
在文本上面。


仍然可以预期,因为你没有宣布它是3倍。

也试过了

< a href ="# section14" class =" drkblue08bold"
onmouseover =" this.style.textDecoration =''none'';"
onmouseout =" this.style.textDecoration =''none'';" >

但有了这个,当页面加载时就行了。


也可以预期。

你可以看到我也没有使用样式表来做这件事,因为
主要做的人网站上的样式已经有一段时间了,所以我们想尽量避免弄乱这项工作,是否可以这样做
没有上面的样式表,或者需要样式表可以
有人展示了如何做到这一点。
is there anyway to make it so that the links are not
underlined when the page loads, when the user moves the mouse over
it''s underlined, mouse out no underline.
Yes, but I doubt if it''s a good thing to do, since most users expect
links to be underlined (appart for menu''s or maybe some other special use).
i tried:

<a href="#section14" class="drkblue08bold"
style="text-decoration:none">

but that left the underline gone forever, the class there is just for
color, color does not change no need to,
Works as expected then.
also tried:

<a href="#section14" class="drkblue08bold"
style="text-decoration:none"
onmouseover="this.style.textDecoration =''none'';"
onmouseout="this.style.textDecoration=''none'';">

but this made it so there was no underline all the time, even if mouse
was over the text.
Still expected, since you declared it 3 times as none.
also tried

<a href="#section14" class="drkblue08bold"
onmouseover="this.style.textDecoration =''none'';"
onmouseout="this.style.textDecoration=''none'';">

but with this the line is there when the page loads.
Also expected.
as you can see i''m also not using style sheets to do this, because the
main person who does the styles on the site is out for a while, so we
want to try to avoid messing with this work, is it possible to do this
without style sheets like above, or is style sheets are needed can
someone show how to do it.




试一试:


< style>

<! -

a {text-decoration:none}

a:悬停{text-decoration:underline}

// - >

< / style>


-

问候

Harrie



Try this in the head:

<style>
<!--
a { text-decoration: none }
a:hover { text-decoration: underline }
//-->
</style>

--
Regards
Harrie


2004年9月11日星期六02:31:03 + 0200,Harrie

< di ****** ************@hotmail.com>写道:
On Sat, 11 Sep 2004 02:31:03 +0200, Harrie
<di******************@hotmail.com> wrote:
试试这个:

< style>
<! -
{text-decoration :无}
a:悬停{text-decoration:underline}
// - >
< / style>
Try this in the head:

<style>
<!--
a { text-decoration: none }
a:hover { text-decoration: underline }
//-->
</style>



除了请假发表评论 - 他们今天没用。除非你支持真正的,非常古老的浏览器。


Except leave out the comments - they''re useless today. Unless you''re
supporting really, really ancient browsers.


Harrie< di *********** *******@hotmail.com>写道:
Harrie <di******************@hotmail.com> wrote:
a:悬停{text-decoration:underline}
a:hover { text-decoration: underline }




这可能会使_all_< a>在鼠标悬停时加下划线的元素(包括< a name =" ..."> ...< / a>

元素),具体取决于
$的解释b $ b:在浏览器中悬停伪类。使用

:link:hover,:visited:hover {text-decoration:underline}

会更安全。


开另一方面,OP应该首先考虑是否首先删除

下划线是一个好主意,并且决定它不是,并且

将CSS问题发布到ciwa未来的样式表。


-

Yucca, http://www.cs.tut.fi/~jkorpela/

有关网页制作的网页: http://www.cs.tut.fi/~jkorpela/www.html br />



This may make _all_ <a> elements (including <a name="...">...</a>
elements) underlined on mouseover, depending on the interpretation of the
:hover pseudoclass in the browser. Using
:link:hover, :visited:hover { text-decoration: underline }
would be safer.

On the other hand, the OP should really first consider whether removing
underline is a good idea in the first place, and decide it is not, and
post CSS questions to c.i.w.a.stylesheets in future.

--
Yucca, http://www.cs.tut.fi/~jkorpela/
Pages about Web authoring: http://www.cs.tut.fi/~jkorpela/www.html


这篇关于链接下划线没有下划线如何?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆