|
|
Joined: Apr 2002
Posts: 68
Power User
|
Power User
Joined: Apr 2002
Posts: 68 |
Is it possible to use css, and have it be able to change an image on the page based on that stylesheet? I have dark, light and everything in between of stylesheets, and I wanted to give each stylesheet an image of its own. For the forum logo. And having a white logo on a dark page doesn't work Just wondering if there’s a way..
"We're sorta like the 7-11. We're not always doin' business, but we're always open"
|
|
|
|
Joined: Mar 2000
Posts: 21,079 Likes: 3
I type Like navaho
|
I type Like navaho
Joined: Mar 2000
Posts: 21,079 Likes: 3 |
If you give that particular <td> it's own class, you can set background images to anything you like based on the stylesheet in use. Something like: background-image: url( https://www.ubbdev.com/threads/php/images/blueblam_r15_c10.gif); is what we use in part of the stylesheet here If we had a green one to choose from as well, the stylesheet would call a green image to do the same thing
|
|
|
|
Joined: Jul 2002
Posts: 135
Journeyman
|
Journeyman
Joined: Jul 2002
Posts: 135 |
I figured out how to get it in the CSS but how do you call it back in the header?
|
|
|
|
Joined: Feb 2001
Posts: 2,268
Junior Member
|
Junior Member
Joined: Feb 2001
Posts: 2,268 |
Create a logo for each style sheet, then in your style sheets add a logo class (I use logo-left, but you can call it anything you want). In that class you need a statement like this one replacing the domain, directory, and image names for your site. All you have to do is change the file name in each style sheet, but use the same class name, and you can have a different logo load for each style sheet. I set up templates for my logo. Check out the first post in this link. You don't have to do what I've done, but it might give you some ideas.
|
|
|
Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.
Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
|
|
Posts: 1,157
Joined: July 2001
|
|
Forums63
Topics37,573
Posts293,925
Members13,849
|
Most Online5,166 Sep 15th, 2019
|
|
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
|
|
|
|
|