Link to home
Create AccountLog in
Avatar of ryanindy

asked on

background image

A client of mine wants me to change the logo on her website to be able to print. It is set as a background image right now. The code on the home page is:

<div id="container">

<div id="header">
      <div id="headerLeft">

Here is the code for "header left" within the style sheet.

      background-position: right;
      background: url(../images/logo.png);
      min-width: 450px;
      height: 105px;

Please tell me how to change the code to geth the logo to print. Thanks!
Avatar of SSupreme
Flag of Belarus image

You cannot force users to print backgrounds, but you can use <img src="images/logo.png" /> instead by replace background.
Avatar of Hagay Mandel
Avatar of ryanindy


Thank you. SSupreme, I don't think I can replace "background: url(../images/logo.png);" with "<img src="images/logo.png" />" in the style.css file can I? If I'm putting an image in the styles.css file it needs to be a background image doesn't it?

And HagayMandel thanks for the link. Can you break it down for me in the code I need to place in my files. I'm confused by their explanations. Sorry, I'm still new at this :) Please see my code above.

Basically, you need to remove logo background from CSS and add <img /> tag with logo to html. After that style tag so it looks the same. could you please proved a link?
Avatar of Hagay Mandel
Hagay Mandel
Flag of Israel image

Link to home
Create an account to see this answer
Signing up is free. No credit card required.
Create Account
Thank you. That worked!