Colors don't Match Up?

Joined: 12/20/2007
User offline. Last seen 21 weeks 3 days ago.

I've recently put together a curvy corner thing. My problem isn't the implementation of the corners though, its that in Firefox it looks great, but in Safari the colors I set using CSS aren't the same as the colors I used in the image. It puzzles me that firefox would work right, but not Safari.

It is just a simple graphic with a curved corner and a drop shadow under it, but the div right beside it should have the same color. This is happening on two different boxes. One is blue (#013893) and the other green (#0B7803). I cut and pasted those in when creating the boxes in my graphics program.

G&G Podcast Host
Matt Farina's picture
Joined: 06/01/2006
User offline. Last seen 3 weeks 2 days ago.
web safe colors

My guess is that this is because you aren't using web safe colors. What are the file types for the images? PNG? JPEG?

Matt Farina
Geeks and God Former Co-Host
www.mattfarina.com

Joined: 12/20/2007
User offline. Last seen 21 weeks 3 days ago.
PNG

They are PNG files.

I'd figured we were out of the "websafe" color days. I thought that was an issue of people's computers not being able to handle true color or something like that and I'm no longer worried about that. Sounds like I made a bad assumption.

G&G Podcast Host
Matt Farina's picture
Joined: 06/01/2006
User offline. Last seen 3 weeks 2 days ago.
Had this problem

I actually ran into this problem last night. My browser and GIMP displayed the same hex code differently. I was working with an image that was all grays in RGB. I switched to gray scale and the problem went away. There can still be issues. I think Photoshop is getter at getting this right. Is that what you were using?

Matt Farina
Geeks and God Former Co-Host
www.mattfarina.com

Joined: 12/20/2007
User offline. Last seen 21 weeks 3 days ago.
Using GIMP

I was using GIMP... (waits for Rob to enter and say "I told you so!") :-)

It seems odd that Firefox would show the colors differently than Safari no matter how they were produced. So do I need to remake my images Photoshop Elements to get this right?

Joined: 12/08/2008
User offline. Last seen 39 weeks 16 hours ago.
Safari supports color

Safari supports color profiles on images, firefox ignores them. I had this same issue the other day. An image wasn't matching the CSS background even though in photoshop it was exact. When I saved my jpeg from Photoshop I made sure no color profile was embedded, and now it looks the exact same in FF or Safari.

here is the site i was having trouble on:
http://deluge6.220power.com

there is a background gradient that fades into the body's CSS color, in Safari it wouldn't quite match, giving an obvious line where the jpg stopped and the css color began.

Jamie

Joined: 12/20/2007
User offline. Last seen 21 weeks 3 days ago.
Oh, that sounds like some

Oh, that sounds like some great info. Thanks Jamie!

Alan Reddick
Alan Reddick's picture
Color in safari

Hey i found an answer to this just make sure when you save an image in photoshop to uncheck the embed profile button.

Joined: 07/15/2010
User offline. Last seen 7 weeks 8 hours ago.
Or (simpler)

Use CSS3 to round the colors and create the drop shadows. That's what it's made for, after all.

Supported right now in every current browser but IE, and will be supported in IE9. You could also use the CSS3PIE behavior (http://css3pie.com/) to add that to earlier versions of IE.

We're never going to make progress in the web design field so long as we hold everyone in the class back to the same speed as the slowest students (meaning, IE). It's time, especially when it comes to good-looking but inessential features such as drop-shadows, rounded boxes, etc., we just let the dumb browsers do without those touches while the capable ones get to show off a little.