+ Reply to Thread
Results 1 to 8 of 8

Thread: CSS...*sigh*

  1. #1
    Conor's Avatar
    Conor is offline Lord Of The Keys Conor is an unknown quantity at this point
    Join Date
    Jan 2005
    Location
    Toronto
    Posts
    1,785

    CSS...*sigh*

    I need CSS help.

    www.elitedrinker.com/flip/ogal981.html

    Looks alright in IE but ever since I edited some of the body code it got messed in FF.

    Also, I want to put in a bg image....and what code do I use to apply the bgcolor of a div to the ENTIRE thing and not just where there is text?

  2. #2
    Bryon is offline Administrator Bryon has disabled reputation
    Join Date
    Apr 2005
    Location
    Northfield, NH
    Posts
    7,608

    Re: CSS...*sigh*

    I'm looking at it, but I'm a little unsure of how it *should* be. Can you give a breif description of what the page should look like?

    To give a background image to an element, you would use somethign along the lines of this:

    Code:
    .whateverClass {
      background-image: url('/path/to/image.gif');
      background-repeat: no-repeat|repeat-y|repeat-x|repeat; /* Pick one. :-) */
      /*... Whatever other properties. */
    }
    Check out http://www.w3schools.com/css/css_background.asp if you don't know the properties, or need help with any of them.

    You said you want the background image to the entire element, not only the text or whatever is in the element. The only thing I can think of that would cause that is that the element has a low height/width set (Whether it's the default behavior of the element, or what you set it to.)

    I would suggest checking out how large your image that you want to have as the background image, then giving the element's, (That you wish to place that image into the background of), height and width more.. static values.

    Such as..

    Code:
    .whateverClass {
      background-image: url('/path/to/image.gif');
      background-repeat: no-repeat|repeat-y|repeat-x|repeat; /* Pick one. :-) */
      /* If your image was 250px x 300px. */
      height: 250px;
      width: 300px;
    }
    Hmmm well yea, I'll wait for you to post back to see about the IE/Firefox problem(s).

  3. #3
    unpixelatedgamers's Avatar
    unpixelatedgamers is offline x10 Lieutenant unpixelatedgamers is an unknown quantity at this point
    Join Date
    Sep 2005
    Location
    Nottingham (England)
    Posts
    337

    Re: CSS...*sigh*

    If you want to apply a background image using CSS put this:
    Code:
    body {
    background-image: url(http://example.com/images/background.jpg);
    }
    Though if you just want it inside a certain area replace the 'body' with your wanted tag or style class.

    And obviously replace http://example.com/images/background.jpg with the directory of the image.

    Also, in your CSS file you need to put a '{' after 'html, body' on line 2 to make it valid css.
    also, in the '#maincol' part of your CSS i would suggest putting a 'px' after the value for width.

    I'm not sure about your next question. though i have personally found that this site has been very useful in helping with coding.

    Edit: Gah, Byron beat me to it.
    Last edited by unpixelatedgamers; 06-11-2006 at 12:25 PM.
    Ignorance is the true enemy of all things.

  4. #4
    Mike-lane is offline Complete IDIOT Mike-lane is an unknown quantity at this point
    Join Date
    Jun 2006
    Posts
    37

    Re: CSS...*sigh*

    From what I'm getting it messes up in both. But it could be because i use IE7.:dunno:
    Last edited by Mike-lane; 06-18-2006 at 05:18 AM.

  5. #5
    careerbridge's Avatar
    careerbridge is offline x10 Sophmore careerbridge is an unknown quantity at this point
    Join Date
    Jun 2006
    Location
    India
    Posts
    126

  6. #6
    Torch's Avatar
    Torch is offline x10 Lieutenant Torch is an unknown quantity at this point
    Join Date
    Apr 2006
    Location
    Belgrade, Serbia
    Posts
    317

    Re: CSS...*sigh*

    Excelent CSS editor is TopStyle. It can really help a lot.

  7. #7
    jensen's Avatar
    jensen is offline x10 Lieutenant jensen is an unknown quantity at this point
    Join Date
    Nov 2005
    Location
    At my desk
    Posts
    438

    Re: CSS...*sigh*

    If you could give a screen shot of what you want your page to look like, you could even use "paint" to sketch it, so that we can give suggestions as to how to write the CSS.

    You are using a lot of DIV's in your page. But what do you expect it to look like? Let us know.

    Are you using http://www.csscreator.com/? It seems to appear in your source.
    Last edited by jensen; 06-19-2006 at 01:15 AM.
    "For I am not ashamed of the gospel of Christ: for it is the power of God unto salvation to every one that believeth" Romans 1:16

  8. #8
    Conor's Avatar
    Conor is offline Lord Of The Keys Conor is an unknown quantity at this point
    Join Date
    Jan 2005
    Location
    Toronto
    Posts
    1,785

    Re: CSS...*sigh*

    No worries its all sorted.

+ Reply to Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
x10hosting free hosting for the masses
dedicated servers