How to disable automatic links coloring without selecting a color?

后端 未结 4 557
梦谈多话
梦谈多话 2021-02-02 06:26

this is really confusing, i don\'t want the browser to change the color of links, so the links color will stay same as specified in . i know that i can

4条回答
  •  渐次进展
    2021-02-02 07:02

    I'm pretty sure there's no way to do what you're describing. But if you want the link color to match the body text color, I'd recommend this...

    The body text color came from somewhere. Probably a CSS definition. Inspect some text in Firebug to see exactly where the applied color was defined. For example, maybe it points you to a rule like this:

    body { color:#666; }
    

    Just add in your A tag right there, so it would be like this. I know it's redundant but I really don't think CSS has a way to say "inherit from one level higher in the cascade than you usually would."

    body, a { color:#666; }
    

提交回复
热议问题