你不能風格默認提示,但你可以使用data-attributes
與使用content:attr(data-attribute);
.tooltip{padding:20px 0;}
.tooltip div {
font: 10px sans-serif;
background-color: blue;
text-align: right;
padding: 3px;
margin: 1px;
color: white;
}
#column1 {
font: 10px sans-serif;
background-color: blue;
text-align: right;
padding: 3px;
margin: 1px;
color: white;
display: inline-block;
position:relative;
}
#column1:after{
content:attr(data-title);
position:absolute;
bottom:100%;
left:100%;
color:#fff;
background:#000;
padding:5px;
display:none;
}
#column1:hover:after{display:block;}
#column2 {
font: 10px sans-serif;
background-color: Red;
text-align: right;
padding: 3px;
margin: 1px;
color: white;
display: inline-block;
position:relative;
}
#column2:after{
content:attr(data-title);
position:absolute;
bottom:100%;
left:100%;
color:#000;
background:#eee;
padding:5px;
display:none;
}
#column2:hover:after{display:block;}
DEMO
回答這個造型messege這裏:http://stackoverflow.com/questions/2011142/how-to-change-the-style-of-title-attribu TE-裏面最錨標籤 – helllomatt 2014-10-06 19:04:32