SitePoint Sponsor

User Tag List

Results 1 to 7 of 7
  1. #1
    Get my greedy down dotJoon's Avatar
    Join Date
    Apr 2003
    Location
    daejeon, South Korea
    Posts
    2,223
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    changing bold text into normal

    I have Guest and Login on the top right at http://dot.kr/x-test/layOut/02/ with strong.

    I like to make the strong Guest and Login to the normal Guest and Login.

    If I remove #guest-login strong in code below, I can get the result which is the normal Guest and Login but it breaks the layOut of the Guest and Login area

    Code:
    #guest-login span, #guest-login strong {
    
     border:1px solid #555;
    
     background:#ffff88;
    
     padding:2px;
    
     overflow:hidden;
    
     display:block;
    
     text-align:center;
    
    }
    How can I make the strong Guest and Login to the normal Guest and Login without breaking the layout?

  2. #2
    Mouse catcher silver trophy Stevie D's Avatar
    Join Date
    Mar 2006
    Location
    Yorkshire, UK
    Posts
    5,892
    Mentioned
    123 Post(s)
    Tagged
    1 Thread(s)
    The easiest way would be to remove the <strong> tag from your HTML, but if you can't do that for some reason then just add font-weight:normal to that bit of the CSS.

  3. #3
    Get my greedy down dotJoon's Avatar
    Join Date
    Apr 2003
    Location
    daejeon, South Korea
    Posts
    2,223
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Stevie D View Post
    The easiest way would be to remove the <strong> tag from your HTML
    The <strong> tag is removed at http://dot.kr/x-test/layOut/03 which has 2 problems; the one is there is no background-color in the block of quest and login, and the other is the text "guest and login are not align-centered.


    Quote Originally Posted by Stevie D View Post
    just add font-weight:normal to that bit of the CSS.
    The result of it is good. Thank you for that.
    but the below code which is at http://dot.kr/x-test/layOut/03 is somewhat awkward.
    Code:
    <strong style="font-weight:normal">Guest</strong>
    <strong style="font-weight:normal">Login</strong>
    How can I replace the awkward code above with the same result of it?

  4. #4
    Get my greedy down dotJoon's Avatar
    Join Date
    Apr 2003
    Location
    daejeon, South Korea
    Posts
    2,223
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    before modified
    Quote Originally Posted by dotJoon View Post
    but the below code which is at http://dot.kr/x-test/layOut/03 is somewhat awkward.
    after modified
    Quote Originally Posted by dotJoon View Post
    but the below code which is at http://dot.kr/x-test/layOut/04 is somewhat awkward.

  5. #5
    Community Advisor silver trophybronze trophy
    dresden_phoenix's Avatar
    Join Date
    Jun 2008
    Location
    Madison, WI
    Posts
    2,821
    Mentioned
    34 Post(s)
    Tagged
    2 Thread(s)
    Dont use CSS inline. It is awkward, and it really paint s you into a corner as far as specificity goes.

    Code:
    #guest-login span, #guest-login strong {
     border:1px solid #555;
     background:#ffff88;
     padding:2px;
     overflow:hidden;
     display:block;
     text-align:center;
    font-weight:normal;
    
    }
    should do the trick.

  6. #6
    Get my greedy down dotJoon's Avatar
    Join Date
    Apr 2003
    Location
    daejeon, South Korea
    Posts
    2,223
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by dresden_phoenix View Post
    Code:
    #guest-login span, #guest-login strong {
     border:1px solid #555;
     background:#ffff88;
     padding:2px;
     overflow:hidden;
     display:block;
     text-align:center;
    font-weight:normal;
    
    }
    Making strong first and back to normal later is not redundancy ?

  7. #7
    Robert Wellock silver trophybronze trophy xhtmlcoder's Avatar
    Join Date
    Apr 2002
    Location
    A Maze of Twisty Little Passages
    Posts
    6,316
    Mentioned
    60 Post(s)
    Tagged
    0 Thread(s)
    STRONG indicates strong(er) emphasis is isn't meant for making text bold, were you actually wanting to make LABEL text for a form?


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
  •