increase font size of hyperlink text html

后端 未结 5 2040
无人及你
无人及你 2021-02-01 07:45

I am working on web application where I have taken href. But the default font of it is too small when comparing to the page. So I want to increase the size of the font.

5条回答
  •  [愿得一人]
    2021-02-01 08:23

    Your font tag is not correct, so it won't work in some browsers. The px unit is used with CSS, not HTML attributes. The font tag should look like this:

    
    

    Well, actually it shouldn't be there at all. The font tag is deprecated, you should use CSS to style the content, like you do already with the text-decoration:

    HTML 5
    

    To separate the content from the styling, you should of course work towards putting the CSS in a style sheet rather than as inline style attributes. That way you can apply one style to several elements without having to put the same style attribute in all of them.

    Example:

    HTML 5
    

    CSS:

    .topic { font-size: 100px; text-decoration: none; }
    

提交回复
热议问题