Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3

Thread: Watermarks

  1. #1
    New Coder
    Join Date
    Aug 2002
    Posts
    14
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Watermarks

    What is the tag to put a watermark in your background. That is where the background picture follows you as you scroll? Thanks

    Chris

  • #2
    umm
    umm is offline
    Regular Coder
    Join Date
    Sep 2002
    Location
    Antipodes
    Posts
    106
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Put this in the head of your HTML document (or in an external style sheet).
    Code:
    <style type="text/css">
    <!--
    body {
    background-image: url("Path to Image");
    background-repeat: no-repeat;
    background-position: center;
    /*
    background-attachment: fixed
    */
    }
    -->
    </style>
    If you remove the comments (/*...*/) from around...
    Code:
    background-attachment: fixed
    ...the text will scoll over the image. Depending on the browser, you may need to write the background image declaration right into the body tag like so.
    Code:
    <body 
    style="background-image: url("Path to Image");
    background-repeat: no-repeat;
    background-position: center;">
    Just make sure you test either method in your preferred browsers.

    hth

  • #3
    Senior Coder Nightfire's Avatar
    Join Date
    Jun 2002
    Posts
    4,265
    Thanks
    6
    Thanked 48 Times in 48 Posts
    Or if you don't want to align it, bgproperties="fixed" in the body tag


  •  

    Posting Permissions

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