Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 4 of 4
  1. #1
    New to the CF scene
    Join Date
    Jan 2007
    Posts
    8
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Span Tag messing up alignment

    I had to add a <span> around a number in order to create up a snippet markup.

    <a href="../learn-spanish-reviews.php" class="linkText">
    <span itemprop="votes">16</span> reviews
    </a>

    Attached is an image (IE8)
    You will see that the '16' next to the word "reviews" is for some reason lower than the word 'reviews'

    I thought the <span> tag was supposed to cause no effect at all.
    Why would the <span> tag be affecting the aligment?

    Thanks for your help

    David

  • #2
    Supreme Master coder! abduraooft's Avatar
    Join Date
    Mar 2007
    Location
    N/A
    Posts
    14,801
    Thanks
    160
    Thanked 2,216 Times in 2,203 Posts
    Blog Entries
    1
    <a href="../learn-spanish-reviews.php" class="linkText">
    <span itemprop="votes">16</span> reviews
    </a>
    Are you able to reproduce the error with just that snippet (and no other HTML+CSS)?
    The Dream is not what you see in sleep; Dream is the thing which doesn't let you sleep. --(Dr. APJ. Abdul Kalam)

  • #3
    New to the CF scene
    Join Date
    Jan 2007
    Posts
    8
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Supreme Master coder Abduraooft,


    Thank you for your reply.

    Did I forget to included the image?
    Here it is now.
    The page is http://www.linguashop.com/learn/spanish.php
    Without the <span> everything is ok.

    Look forward to hearing from you.

    David
    Attached Thumbnails Attached Thumbnails Span Tag messing up alignment-16reviews.jpg  

  • #4
    Master Coder Excavator's Avatar
    Join Date
    Dec 2006
    Location
    Alaska
    Posts
    9,666
    Thanks
    22
    Thanked 1,826 Times in 1,810 Posts
    Hello kembreg,
    A good argument here for not resetting browser defaults. http://meiert.com/en/blog/20080419/r...heets-are-bad/



    See what happens when you comment this out, see highlighted in red -
    Code:
    /*==========
     RESET PART
     ==========*/
    html, body, div, span, object, iframe,
    h1, h2, h3, h4, h5, h6, p,
    blockquote, pre, abbr, address, cite, code,
    del, dfn, em, img, ins, kbd, q, samp, small, strong,
    sub, sup, var, b, i, dl, dt, dd, ol, ul, li,
    fieldset, form, label, legend,
    table, caption, tbody, tfoot, thead, tr, th, td,
    article, aside, dialog, figure,
    footer, header, hgroup, menu, nav,
    section, time, mark,
    audio, video 	{
    margin:0;
    padding:0;
    border:0;
    outline:0;
    font-size:100%;
    /*vertical-align:middle;*/
    background:transparent
    }
    Validate often DURING development - Use it like a splelchecker | Debug during Development |Write it for FireFox, ignore IE
    Use the right DocType | Validate your markup | Validate your CSS | Why validating is good | Why tables are bad


  •  

    Posting Permissions

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