Why is the
tag deprecated in HTML?

前端 未结 12 1641
攒了一身酷
攒了一身酷 2020-11-22 01:36

I am just curious as to why the

tag in HTML was deprecated.

The

was a simple way of quickly center-aligning b
12条回答
  •  甜味超标
    2020-11-22 02:17

    I still use the

    tag sometimes because nothing in CSS works as well. Examples of trying to use a
    trick and failing:

    This div is centered, but it's a simple example.

    <div style="text-align: center;"> didn't center correctly.

    <div style="text-align: center;margin-left:auto;margin-right:auto"> still didn't center either

    Actually Centered with <center> tag

    gets results. To use CSS instead, you sometimes have to put CSS in several places and mess with it to get it to center right. To answer your question, CSS has become a religion with believers and followers who shunned
    as blasphemy, unholy, and much too simple for the sake of their own job security. And if they try to take your away from you, ask them what the CSS equivalent of the colspan or rowspan attribute is.

    It is not the abstract or bookish truth, but the lived truth that counts.
    -- Zen

    提交回复
    热议问题