Magento Expert Forum - Improve your Magento experience

Results 1 to 11 of 11

Do all HTML tags come in pair?

  1. #1

  2. #2
    Junior Member
    Join Date
    Oct 2016
    Posts
    358
    Thanks
    0
    Thanked 2 Times in 2 Posts

    Default

    Most of tags are come in pair but some of tags are not required closing tags. These tags are called self closing tags. For example, <hr>, <br>.

  3. #3
    Junior Member
    Join Date
    May 2017
    Posts
    12
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    For self closing tags, you also can use <br/> or <hr/>

  4. #4
    Junior Member
    Join Date
    Jul 2017
    Location
    Delhi
    Posts
    62
    Thanks
    0
    Thanked 2 Times in 2 Posts

    Default

    Nopss...there is tag <br> tag is html is not use in pair but work as individual tag when designing a website.

  5. #5
    Junior Member
    Join Date
    Mar 2017
    Location
    Delhi
    Posts
    186
    Thanks
    0
    Thanked 1 Time in 1 Post

    Default

    NO, not all the HTML tags do not come in pair like
    <br />
    <area />
    <base />
    <col />
    <embed />
    <image />
    <hr />
    <br />
    <wbr />
    <source />
    <meta />
    <link />
    <input />

  6. #6
    New member
    Join Date
    May 2016
    Location
    Jalandhar, Punjab, India
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    You can use </ br> tag for self closing.

  7. #7
    Junior Member kajal's Avatar
    Join Date
    Sep 2014
    Location
    Bangalore
    Posts
    441
    Thanks
    0
    Thanked 7 Times in 7 Posts

    Default

    All tag come in pairs except for Void elements, which at the time of this writing include: area, base, br, col, embed, hr, img, input, keygen, link, meta, param, source, track, and wbr.

  8. #8
    Junior Member
    Join Date
    Apr 2017
    Posts
    133
    Thanks
    0
    Thanked 1 Time in 1 Post

    Default

    No not always all tags are in pair. Use some other tags like </ br>

  9. #9
    Junior Member
    Join Date
    Feb 2017
    Posts
    13
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Quote Originally Posted by barbara glowam View Post
    Most of tags are come in pair but some of tags are not required closing tags. These tags are called self closing tags. For example, <hr>, <br>.
    The best reply, nothing to add here. Just remembered about free html tools from Templatemonster available now https://www.templatemonster.com/blog...imation-tools/ , if you're eager to create an animation - these products will be extremely useful. Good luck!

  10. #10
    New member
    Join Date
    Jan 2018
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    You can use </ br> tag for self closing.

  11. #11
    Junior Member petershene's Avatar
    Join Date
    Aug 2017
    Location
    South Africa
    Posts
    17
    Thanks
    3
    Thanked 0 Times in 0 Posts

    Default

    HAhai used to type <br></br> so much and i always thought it was weird how the spaces where so big ( it counts both as a break ) . When i ran it through w3 it always used to show an error but not explain thqat this is a self closing tag . Ther are only a few i know of <col />
    <command />
    <embed />
    <hr />
    <img />
    <input />
    <keygen />
    <link />
    <meta />
    <param />

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •