WordPress.org

Ready to get started?Download WordPress

Forums

random image with css (5 posts)

  1. ruffy
    Member
    Posted 7 years ago #

    hi everybody,

    i have got the DRUNKEY LOVE THEME.
    I would like to change as following:

    #blog-title {
    vertical-align: text-bottom;
    float: left;
    width: 270px;
    height: 200px;
    text-transform: lowercase;
    font: 1.7em "Apple Garamond", "Garamond", serif;
    text-align: right;
    background: #333 url(images/bg-title.jpg) repeat-x;
    color: #fff;
    }

    this is the code from my stylesheet. I would like to RANDOMIZE the bg-title.jpg.
    I´ve had the minima plus theme and implemented a random header with masthead. this was easy, but i cant figure out how to randomize THIS particular image.
    as u can see from the code, it´s in the HEAD and is part of the navigation. it´s the backgroundimage of the "home button". but it´s not shown as an image in the HEADER template. css is used to style this one. so if anyone figures out a way for me to RANDOMIZE this, please tell me :)
    thanks in advance and sorry for my english.

    greetz
    ruffy

  2. ZMAng
    Member
    Posted 7 years ago #

    If you're looking to randomize an image, try this PHP script. It works for CSS images (like your bg-title.jpg) as well. A comprehensive guide is included.

  3. ruffy
    Member
    Posted 7 years ago #

    I´ll try this one. thank you.

  4. incertus
    Member
    Posted 7 years ago #

    Another thing you could look at is the technique found here; http://codegrrl.com/!/tutorials/view/randomize_pretty_much_anything/

    As it says -- with it you can randomize just about anything including background images using css

  5. ruffy
    Member
    Posted 7 years ago #

    hi,
    ZMAng´s link worked fine. thanks to everyone, who even thought about this :)
    incertus: i saved ur link, thx :)

    hope this helps others too :)

Topic Closed

This topic has been closed to new replies.

About this Topic