Solved

Table colors and images

Posted on 2004-10-19
5
178 Views
Last Modified: 2010-04-06
Here is what I am trying to do.  With the help of a member I was able to finally figure out my online coupon with the following code, works great!:

<html><head>
<style>
.coupon {
     border: 2px gray dashed;
     width: 400px;
     padding: 5px;
}
</style>
</head><body>
<div class="coupon">
     This is your wonderful coupon!<br />
     Print it out to recieve $0.50 cents off your next can of cat food!<br />
     Enjoy Kitty Loves Me brand!<br />
</div>
</body></html>

What I would like to happen and I have tried it a few ways without any luck.  I would like the table background say a light gray and when it prints it is a light gray.  But when I try that it comes out white since the table color will not print.  Is there a way to do like an image under then I can overlay my text?

0
Comment
Question by:precision
  • 2
  • 2
5 Comments
 
LVL 13

Expert Comment

by:nurbek
ID: 12346284
it depends on the Browser settings

from the Tools -> Internet Options -> Advanced

check the "Print background colors and images"

:)




 
0
 

Author Comment

by:precision
ID: 12346382
That is good for my machine, I want something that anyone who prints, it will print out in color.  Like an image table background that I can overlay text on.
0
 
LVL 13

Expert Comment

by:nurbek
ID: 12346403
anyone who wants to print it out with colors
they also should change their browser settings
0
 
LVL 53

Accepted Solution

by:
COBOLdinosaur earned 250 total points
ID: 12346717
What I would like to happen and I have tried it a few ways without any luck.  I would like the table background say a light gray and when it prints it is a light gray.  But when I try that it comes out white since the table color will not print.  Is there a way to do like an image under then I can overlay my text?

You cannot control user settings.  You have no way of knowing what kind of printer the user has.  Images in general do not print well. You could us a layer wiht an image an then overlay the text, but that will require absolute positioning, and the position of the test and image will not line up the some when it is printed about 75% of the time.

If an image is critical then you will have to do the page with a print friendly format like PDF.  If color is important, then you are going to be disappointed because only a small percentage of users are going to have color printing capabilities.

Cd&
0
 
LVL 53

Expert Comment

by:COBOLdinosaur
ID: 12346847
Glad we could help.  Thanks for the A. :^)

Cd&
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

I will show you how to create a ASP.NET Captcha control without using any HTTP HANDELRS or what so ever. you can easily plug it into your web pages. For Example a = 2 + 3 (where 2 and 3 are 2 random numbers) Session("Answer") = 5 then we…
Have you tried to learn about Unicode, UTF-8, and multibyte text encoding and all the articles are just too "academic" or too technical? This article aims to make the whole topic easy for just about anyone to understand.
HTML5 has deprecated a few of the older ways of showing media as well as offering up a new way to create games and animations. Audio, video, and canvas are just a few of the adjustments made between XHTML and HTML5. As we learned in our last micr…
Video by: Mark
This lesson goes over how to construct ordered and unordered lists and how to create hyperlinks.

896 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now