Everybody! This is important. In a few days, these forums will be moving over to using the totally sweet Discourse platform. To ensure this migration happens smoothly with no loss of content, these forums are currently in a read-only mode. I do apologize for the inconvenience.

There is never a good time to turn the forums off for an extended period of time, but I promise the new forums will be a billion times better. I'm pretty sure of it.

See you all on the other side in a few days, and if you have any (non-technical) questions, please e-mail me at kirupa@kirupa.com. For technical questions, try to find a tutorial that corresponds to what you are looking for and post in the comments section of that page.

Cheers,
Kirupa

Results 1 to 9 of 9

Thread: Setting the CSS border length?

  1. #1

    Setting the CSS border length?

    Im brand new to CSS and im starting to learn it, i making a table, and this is what i have so far :


    style type="text/css">
    h3 {text-indent: .1cm}
    h3 {font-family: Verdana}
    h3 {color: #666666}
    h3 {font-size: 90%}
    h3
    {
    border: 2px dashed #cccccc
    }


    I need to the lenght of the border now....

    Thank You

  2. #2
    I need to the lenght of the border now....
    Could you be more specific? Do you mean height?

  3. #3
    No, i mean the length of the whole table....

  4. #4
    You can't do it just for the border. You need to define the width: and/or height: attribute in the CSS for the h3, and the border will adapt around that. BTW... never use multiple tags for the same element, combine them in one (this includes example of adding width and height to it...

    PHP Code:
    <style type="text/css">
    h3 {
        
    width400px;
        
    height100px;
        
    text-indent.1cm;
        
    font-familyVerdana;
        
    color#666666;
        
    font-size90%;
        
    border2px dashed #cccccc;
        
    }
    </
    style

    Though i'm a bit rusty on CSS... perhaps I am wrong and h3 tags don't support width and height (like those retched span tags!... you gotta love em, but they lack support for a lot of CSS features)

  5. #5
    Ok, thank you.

  6. #6
    Quote Originally Posted by lostinbeta
    You can't do it just for the border. You need to define the width: and/or height: attribute in the CSS for the h3, and the border will adapt around that. BTW... never use multiple tags for the same element, combine them in one (this includes example of adding width and height to it...

    PHP Code:
    <style type="text/css">
    h3 {
        
    width400px;
        
    height100px;
        
    text-indent.1cm;
        
    font-familyVerdana;
        
    color#666666;
        
    font-size90%;
        
    border2px dashed #cccccc;
        
    }
    </
    style

    Though i'm a bit rusty on CSS... perhaps I am wrong and h3 tags don't support width and height (like those retched span tags!... you gotta love em, but they lack support for a lot of CSS features)
    Haha, never thought about using a display:block; on those span elements, have you?

    You can only set heights and widths to elements that aro of the type 'block'. Most elements are that default, but some (like strong and span) are inline.

  7. #7
    Like I said... i'm rusty on my CSS... and now i'm rusty on my CSS and very appreciative of the new info!

  8. #8

    border-length: [value];

    border-length: [value];
    will work in css3.

  9. #9
    Quote Originally Posted by Sawan Gupta View Post
    border-length: [value];
    will work in css3.
    I think this will adjust the size of border but not its length which he is asking for.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

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

Home About kirupa.com Meet the Moderators Advertise

 Link to Us

 Credits

Copyright 1999 - 2012