7 replies [Last post]
franco_bao
Offline
Regular
Montreal, Canada
Last seen: 14 years 6 weeks ago
Montreal, Canada
Timezone: GMT-4
Joined: 2006-05-03
Posts: 21
Points: 0

I have recently adapted a scree type css into a print css. Things have been looking good until I did a print out of my site in Firefox. it seems that the background image that I have placed inside the css of the company logo seems to print very small inside Firefox, but it is fine inside IE. Is there something that I need to add in the css to print background images with firefox from a css stylesheet.

Here is an example of such a page. if you are to print this page in Firefox and IE you will noticed that the company logo is much smaller in Firefox.

Here is the link to the page:
http://www.interdoc.com/site/solutions/business_intelligence.htm

It's funny because when i do a print preview, I see it the way it should print.

Thanks in advance

Tyssen
Tyssen's picture
Offline
Moderator
Brisbane
Last seen: 7 years 14 weeks ago
Brisbane
Timezone: GMT+10
Joined: 2004-05-01
Posts: 8201
Points: 1386

Re: Print css with background images

franco_bao wrote:
if you are to print this page in Firefox and IE you will noticed that the company logo is much smaller in Firefox.

Actually I don't because I haven't set up either browser to print background images. The default for most (if not all) browsers is to not print background images. You have to physically alter your settings to allow this to happen. So essentially you're worrying about something that a fairly large proportion of users will never even see.

How to get help
Post a link. If you can't post a link, jsFiddle it.
My blog | My older articles | CSS Reference

Hugo
Hugo's picture
Offline
Moderator
London
Last seen: 7 years 2 weeks ago
London
Joined: 2004-06-06
Posts: 15668
Points: 2806

Print css with background images

However the question is about the discrepancy between what one sees in print preview and what actually prints out, so for the moment whether background printing is enabled or disabled is somewhat irrelevant.

I'm afraid I'm not prepared to run a print off of the page as thats a cost to myself in consumables and ink is expensive in the UK (sorry I'm tight) Not sure what to suggest as a possible problem, one thing you may play with is the values you're using to express the dimensions of the background container, other than that I cant think of a reason this would be happening, but would have thought that it is possible more a problem resting with your setup ( what have you got the scaling factor set to in FF) rather than the actual CSS/HTML coding.

Hugo

Before you make your first post it is vital that you READ THE POSTING GUIDELINES!
----------------------------------------------------------------
Please post ALL your code - both CSS & HTML - in [code] tags
Please validate and ensure you have included a full Doctype before posting.
Why validate? Read Me

Tyssen
Tyssen's picture
Offline
Moderator
Brisbane
Last seen: 7 years 14 weeks ago
Brisbane
Timezone: GMT+10
Joined: 2004-05-01
Posts: 8201
Points: 1386

Print css with background images

Hugo wrote:
However the question is about the discrepancy between what one sees in print preview and what actually prints out, so for the moment whether background printing is enabled or disabled is somewhat irrelevant.

No it's not. I checked the page in print preview and saw no logo at all so therefore assumed that franco must have 'print background images' enabled which is not the default behaviour.

How to get help
Post a link. If you can't post a link, jsFiddle it.
My blog | My older articles | CSS Reference

Hugo
Hugo's picture
Offline
Moderator
London
Last seen: 7 years 2 weeks ago
London
Joined: 2004-06-06
Posts: 15668
Points: 2806

Print css with background images

:? what!

I too had background printing disabled, so I enabled it and checked in both IE and FF and confirmed that indeed the logo size was indeed the same in both.

Of course the assumption is that the OP has backgrounds enabled otherwise the question would have been "why cant I see my logo in print preview" it wasn't! again the issue of enabling 'print background' is spurious to the original question/problem, re-read the original post.

Before you make your first post it is vital that you READ THE POSTING GUIDELINES!
----------------------------------------------------------------
Please post ALL your code - both CSS & HTML - in [code] tags
Please validate and ensure you have included a full Doctype before posting.
Why validate? Read Me

Tyssen
Tyssen's picture
Offline
Moderator
Brisbane
Last seen: 7 years 14 weeks ago
Brisbane
Timezone: GMT+10
Joined: 2004-05-01
Posts: 8201
Points: 1386

Re: Print css with background images

franco_bao wrote:
Is there something that I need to add in the css to print background images with firefox from a css stylesheet.

That is the original question. My original answer is perfectly reasonable in relation to that question.

How to get help
Post a link. If you can't post a link, jsFiddle it.
My blog | My older articles | CSS Reference

franco_bao
Offline
Regular
Montreal, Canada
Last seen: 14 years 6 weeks ago
Montreal, Canada
Timezone: GMT-4
Joined: 2006-05-03
Posts: 21
Points: 0

thanks

Didn't mean to cause a debate... LOL. The reason I have the image in background, is so that I can control what is shown from different media types. Eventually would like to have a pda stylesheet and call up a smaller logo. I did not know that background printing was deactivated by default. I have mine to work and don't remember setting it up as that it is changed from default.

Since Hugo has printed it out and he gets them both the same size, I'll have to run my tests from my print setup and see if it is something on my computer.

Thank you both for your valuable input. I will play around with my set up and let you know what the actual problem on my end was. Again, Thanks... always helpful.

franco_bao
Offline
Regular
Montreal, Canada
Last seen: 14 years 6 weeks ago
Montreal, Canada
Timezone: GMT-4
Joined: 2006-05-03
Posts: 21
Points: 0

Print css with background images

Just one small note. When i preview the page, in both IE and FF, I see see the logo as it is soppose to appear, the problem occurs when I print it. That is why I find this strange, why it does not print as the preview shows it to me. Will continue my quest.