changing header in .css

outern

New Member
When i change the header target in the .css script. It wont change to the new image header. It just go blank instead. I am sure it is in the right spot and so on.


#logo {
width: 1036px;
height: 204px;
background: url(images/header.jpg) repeat-x;
}
 

AusQB

New Member
Try refreshing the view in whatever program you are using. Sometimes it doesn't recognize a new file being added to the directory.

If refreshing doesn't work, just restart the program.
 

conor

New Member
what are you changing it from and what to? If you give us the original and edited code we can diagnose the problem.

Thanks
 

outern

New Member
Orginal:

#logo {
width: 1036px;
height: 204px;
background: url(images/header.jpg) repeat-x;
}

New:

#logo {
width: 1036px;
height: 204px;
background: url(images/header2.jpg) repeat-x;
}


I just want to change to another header named header2.jpg in the images folder.

I have tried restarting th eprogram and so on, It didn`t help. it has the same size as the last header.
 

adx

New Member
Newerer:

#logo {
width: 1036px;
height: 204px;
background-image: url(images/header2.jpg);
background-repeat: repeat-x;
}

Should work. Unless it's supposed to be /images/header
 

AusQB

New Member
I'm not sure if it makes a difference, but try putting single quotes (') around the image filepath.

ie. background-image: url('images/header2.jpg');
 

conor

New Member
try using the original code and just copy over the header.jpg file with your new file. If it still doesn't display try looking at it with firebug or something - that should let you know what's wrong.

Can you give us a link?
 

outern

New Member
Havnt published it yet. I will try to fix it with theese other tips. if not i will get it on a server and post a link.
 

PixelPusher

Super Moderator
Staff member
I'm not sure if it makes a difference, but try putting single quotes (') around the image filepath.

ie. background-image: url('images/header2.jpg');

I never add [''] in the image location. It may not break the code but I don't think that is correct syntax.

As far as breaking the background element into seperate sections (color, image, etc.), this is just the long hand version. Using [background:color url() repeat attachment position] in one line just shortens your css. Neither method is incorrect though.

Are you using a button to change the header? what triggers the change?
 
Top