Results 1 to 3 of 3

Thread: DIV crazy

  1. #1
    Join Date
    Dec 2004
    Posts
    26

    Default DIV crazy

    I am still working on getting my site up and running, however I have discovered two things.
    1: I use wayyyyyy too many divs to get my site to work the way I want it to.
    2: I cannot get the page to center (only the text withing the divs)

    and I have one question.
    Is there any way to get a scroll bar inside of a div (if I keep using that as my solution) so that it retains it shape and readability.

    http://zostix.bizhat.com/new.html

    If anyone could take a look and let me know that would be great. I am new to XHTML and need all the advice I can get

  2. #2

    Default

    Yes. In your stylesheet; add a rule for divs:

    Code:
    DIV
    {
    	overflow: auto; /* Adds scrollbars to the div, if needed */
    	width: 100px;   /* Sets width */
    	height: 100px;  /* Sets width */
    	padding: 5px;   /* Sets padding for text inside div. */
    }
    You can use <center>-tags to center or add the attribute align="center" to the div tag to center it.

    Hope this helps.

  3. #3
    Join Date
    Dec 2004
    Posts
    26

    Default

    thanks I will try this out today.

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
  •