php forum
php mysql forum
php mysql smarty
 
Topic Options
#226770 - 10/25/02 08:03 PM question, (images)
caspe7_dup1 Offline
Power User

Registered: 04/14/02
Posts: 75
Loc: Long Beach, CA, USA

   question, (images) to Del.icio.us Add to del.icio.us
  Digg question, (images) Digg it
Is it possible to use css, and have it be able to change an image on the page based on that stylesheet? <br /><br />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<br /><br />Just wondering if there’s a way.. <img src="/forum/images/graemlins/smile.gif" alt="" /><br />
_________________________
"We're sorta like the 7-11. We're not always doin' business, but we're always open"

Top
#226771 - 10/25/02 09:13 PM Re: question, (images) [Re: AgentDrek]
AllenAyres Administrator Offline
I type Like navaho

Registered: 03/10/00
Posts: 25411
Loc: Texas
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:<br /><br />background-image: url(http://www.threadsdev.com/threads/php/images/blueblam_r15_c10.gif);<br /><br />is what we use in part of the stylesheet here <img src="/forum/images/graemlins/smile.gif" alt="" /> If we had a green one to choose from as well, the stylesheet would call a green image to do the same thing <img src="/forum/images/graemlins/smile.gif" alt="" /><br />
_________________________
- Allen wavey
- What Drives You?

Top
#226772 - 01/20/03 04:26 PM Re: question, (images) [Re: SurfMinister]
SchoolScandals Offline
Journeyman

Registered: 07/27/02
Posts: 138
I figured out how to get it in the CSS but how do you call it back in the header?

Top
#226773 - 01/21/03 01:00 AM Re: question, (images) [Re: TestPappy]
Dalantech Offline
Junior Member

Registered: 02/11/01
Posts: 2392
Loc: Naples, Italy
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<br /><br />
Code:
 background-image: url(http://www.yourdomain.com/somedirectory/some-logo.gif); 
<br /><br />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.<br /><br />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.
_________________________
Da LAN Tech

Threads Dev Moderator

Top


Top Posters Last 30 Days
AllenAyres 12
Gizmo 10
S7ARBVCK 2
Cambridge 1
Murphdog 1
MattUK 1
Kevin H 1
Who's Online
0 Registered (), 31 Guests and 10 Spiders online.
Key: Admin, Global Mod, Mod
Shout Box

Latest Posts
BeyondCompare v3.00
by blaaskaak
Today at 02:46 PM
Noob - need help, or a reality check!
by Gizmo
Yesterday at 03:21 AM
Here I am! Rock me like a Hurricane!
by AllenAyres
09/02/08 03:05 PM
[7.x] Generic Page Outside of forum directory
by Gizmo
08/30/08 05:43 PM
Team UBBDev Rides Again!
by Gizmo
08/28/08 11:45 PM
Multiple Identity Detector
by MattUK
08/28/08 04:10 PM
[7.3.x] ubb.links
by AllenAyres
08/26/08 09:57 AM
New Mods
Installing FlashChat with 7.3
by Paug
08/23/08 12:14 AM
[7.3.x] ubb.links
by AllenAyres
06/20/08 11:50 PM
[7.2.1] - Naked shoutbox
by sirdude
08/17/07 10:36 PM
[7.x] Generic Page Outside of forum directory
by
01/14/07 10:58 PM
Multiple Identity Detector
by
12/30/06 06:39 PM
Newest Members
veedubb8, twentyseven, Claus1, welcomeback1, Paug
13327 Registered Users

 

 

 
fusionbb message board php hacks