SitePoint Sponsor

User Tag List

Results 1 to 9 of 9
  1. #1
    SitePoint Member
    Join Date
    Feb 2002
    Posts
    23
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    div tag, i need help

    how do i make a div textarea with a scrollbar in it. and if i want its positioned fixed how would i do that

    <div style="width:120;height:95;overflow:auto;position:absolute;top:363;left:334">
    text
    </div>

    this is what i found from a website. i wanna know if its right. also how do they know were to fit it our the width and height is their a program that does it or do they just keep typing random numbers in?

  2. #2
    SitePoint Member
    Join Date
    Jun 2002
    Location
    Toronto, Canada
    Posts
    2
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Wink <div> tag



    The DIV tag has particular attributes and none of them include a textarea, so I am really interested in seeing the site where you found this piece of code.

    For more information on <div> tags please check out:
    http://html.about.com/library/weekly/aa011000a.htm

    Maybe you could describe what you are trying to accomplish?

    Jarob Designs
    To design, to create with passion!

  3. #3
    SitePoint Evangelist CyberFuture's Avatar
    Join Date
    May 2001
    Location
    San Diego, CA
    Posts
    434
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    The <div> tag is being used to define a layer using CSS.

  4. #4
    SitePoint Enthusiast Jack@dwd.com's Avatar
    Join Date
    Dec 2000
    Location
    UK
    Posts
    60
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Why don't you try it yourself by making a page and putting some content in it ?

    The attribute that makes this scroll-box in a page is the overflow: auto; one - unfortuanately, I don't think this is supported in many browsers (and if it is supported in any, it will be Mozilla 1 and Netscape 7).

  5. #5
    SitePoint Member
    Join Date
    Feb 2002
    Posts
    23
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    it works in IE 6. what im asking is how do i get the fixed position. do i just guess the #. or do i use a program that gives me the #s.

    an what i am trying to accomplish is a textarea w/ scrollbar in a specific location that is fixed using the div tag. it would look something like this but it would be on the square thingy

    http://goku-deedlit.hypermart.net/test1.htm

    how do i get the text box to fix the box
    Last edited by RaYoVaC; Jun 25, 2002 at 12:42.

  6. #6
    SitePoint Evangelist CyberFuture's Avatar
    Join Date
    May 2001
    Location
    San Diego, CA
    Posts
    434
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    width:120; // the width of the layer.
    height:95; // the height of the layer.
    overflow:auto; // makes a scroll bar if layer content is larger than layer
    position:absolute; // makes layer position fixed
    top:363; // distance in pixel that the top of the layer is from the top browser window
    left:334 // same as above, but leftside

    You should also consider using a background color:

    background-color: #CC0000; layer-background-color: #CC0000;

  7. #7
    SitePoint Member
    Join Date
    Feb 2002
    Posts
    23
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    i see what u mean but am i suppose to guess those coordinates??

  8. #8
    SitePoint Evangelist CyberFuture's Avatar
    Join Date
    May 2001
    Location
    San Diego, CA
    Posts
    434
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You can use software like DreamWeaver, which allows you to layout your layers visually and automatically creates the numbers. Or you can do it by hand (guessing).
    Last edited by CyberFuture; Jun 26, 2002 at 11:49.

  9. #9
    SitePoint Zealot yuri's Avatar
    Join Date
    Oct 2001
    Location
    Just Round The Corner!
    Posts
    166
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Dreamweaver if ya got it

    i would advise dreamweaver if ya got it and even if ya aint, i would advise it. insert a layer and plonk it where u want it. u could also have a table and convert it to layers. this would give you a bit more of an exact position.

    chris


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
  •