Dung CSS thay cho 1 số thuộc tính HTML

0
0
(0)

  Dùng CSS thay cho 1 số thuộc tính HTML "lỗi thời" 

   

Ví dụ:
Thay vì dùng tag b thì ta dùng font-weight, thay vì dùng tag sub thì ta dùng vertical-align: sub

2) Thay thế các thuộc tính HTML lạc hậu bằng cách dùng CSS
Ví dụ:
Thay vì dùng thuộc tính background của tag body hoặc tag td, thì ta dùng thuộc tính CSS background

CSS

Deprecated

<APPLET> N/A Y
<B> font-weight  
<BASEFONT> font-size, font-family Y
<BIG> font-size  
<BLINK> text-decoration: blink;  
<CENTER> margin-left: auto; margin-right: auto; Y
<DIR> UL+style Y
<EM> font-style: italic;  
<FONT> font-family, font-size Y
<HR> border-top: solid;  
<I> font-style: italic;  
<ISINDEX> N/A Y
<MENU> UL+style Y
<STRIKE> text-decoration: line-through; Y
<S> text-decoration: line-through; Y
<SMALL> font-size  
<STRONG> font-weight: bold;  
<SUB> vertical-align: sub;  
<SUP> vertical-align: sup;  
<TT> font-family: monospace;  
<U> text-decoration: underline; Y

HTML Attributes

HTML Attributes: Translations to CSS

HTML Attribute

of HTML Element

CSS

Deprecated

align see file float, text-align Y
alink <BODY> A:active Y
background <BODY><TD> background Y
bgcolor <BODY> background-color Y
clear <BR> clear Y
compact <LIST> display: compact Y
face, size <FONT> font-family: Arial; Y
link <BODY> A:link Y
noshade <HR> CSS default is solid Y
start <LIST> content: counter Y
text <BODY> color Y
type <LIST> list-style-type Y
value <LIST> LI:before Y
vlink <BODY> A:visited Y
width <HR> width Y

Tham khảo: http://www.dev-archive.net/articles/translate.html

Sưu tập

How useful was this post?

Click on a star to rate it!

Average rating 0 / 5. Vote count: 0

No votes so far! Be the first to rate this post.

Leave A Reply

Your email address will not be published.