2011-08-11 76 views
0

我有結果A HREF鏈接在jQuery按鈕jQuery的按鈕A HREF文本

$("a.button, button, input:submit", "div").button(); 

<a href="/Home/Acton" class="button">Back</a> 
<button name="submit" id="continue" value="continue">Continue</button> 

我有:

enter image description here

所以,問題是,Back文本A HREF不白色,爲了解決我添加了下面的樣式。

/*jQuery buttons a href style fix*/ 
a.button:link {color: #fff !important;} 
a.button:hover {color: #026890;} 

我可以在應用的風格螢火看到,但它是沒有幫助的Back文本仍然不是白色。

事情是,當Back是懸停它看起來不錯,但不懸停時文本應該是白色的像Continue一樣的方式,但事實並非如此。

我該如何解決這個問題?

回答

2

您沒有設置a:visited是爲什麼你有這樣的情況這就是白,也可能設置a:hover#026890

所以嘗試:

/*jQuery buttons a href style fix*/ 
a.button:link {color: #fff !important;} 
a.button:visited {color: #fff !important;} 
a.button:active {color: #026890 !important;} 
a.button:hover {color: #026890 !important;} 
+0

+1 - 只是打我吧! – ipr101

0

難道「返回」鏈接已被訪問?如果你設置鏈接的「訪問」版本的css是否解決了這個問題?

0

您可以通過使用此代碼解決這個問題:

a.button {color: #fff} 
a.button:hover {color: #026890;}