HTML: printing radio buttons

I have noticed that when I try to print an HTML form that I designed (printing is initiated from the Print button in the Internet Explorer toolbar; I'm using IE6), that radio buttons do not show up on the page.  The *captions* of the buttons show up, but there is blank space next to them where the button would be, so of course there is no way to tell which button is checked.

I am aware that I could change those buttons to be checkboxes or dropdown lists, and those controls do show up on paper, but I have a lot of radio buttons that would need to be changed, and was wondering whether there was some way to cause radio buttons to print properly (perhaps some stylesheet setting?).

Thanks in advance for your help.
Who is Participating?
leslynfConnect With a Mentor Commented:
BTW, it isn't necessarily something in the radio button code -- it could be a missing quote somewhere in your code, or a missing closing bracket (>) of some item, etc. You need to look at that as well.

Leslyn :)
That is not the default behaviour - they should print just fine. (For example, try doing a Print Preview from this page.)

There must be something in your code that is causing this...

Show me your code for your radio buttons.

Leslyn :)
Cloud Class® Course: Ruby Fundamentals

This course will introduce you to Ruby, as well as teach you about classes, methods, variables, data structures, loops, enumerable methods, and finishing touches.

mlcktmguyAuthor Commented:

I don't seem to be able to print radio buttons from ANY website, but here is an example of the code from the page I created:

<input type=radio name=rdEstGoal value=Y>
<font size=1 face=Verdana,Arial,Helvetica,Geneva,Swiss,SunSans-Regular>Yes
<input type=radio name=rdEstGoal value=N>No</font>

I have also come to realize that this is likely not an HTML issue, but rather a printer issue.  On my HP OfficeJet, I cannot get radio buttons to print from any site, and other people with newer HP printers are reporting the same problem.  However, my page IS being successfully printed - radio buttons and all - on an HP LaserJet and even on an older-model HP DeskJet.

I have tried various printer settings on my OfficeJet, so far without any improvement.
OK. Here's the problem. A radio button (within a set) must ALL have the same name, or they will not work correctly. The Value (if chosen) should Not be "Y" or "Yes," In other words, if the person selects one of these, that particular one should reflect the value that would be placed in the field for the category they are choosing.

Here's a simple example of selecting method of payment:

<B>Please select your method of payment:</B><BR>
<INPUT TYPE="radio" NAME="pmttype" VALUE="amex">American Express<BR>
 <INPUT TYPE="radio" NAME="pmttype" VALUE="mc">MasterCard<BR>
<INPUT TYPE="radio" NAME="pmttype" VALUE="visa">Visa<BR>
<INPUT TYPE="radio" NAME="pmttype" VALUE="disc">Discover<BR>
<INPUT TYPE="radio" NAME="pmttype" VALUE="debit">Bank Debit<BR>

If I want one of them to be selected in advance (the default), then I would include the attribute CHECKED in the INPUT tag:

<INPUT TYPE="radio" NAME="pmttype" VALUE="amex" CHECKED>American Express<BR>

The VALUE will go into the field called pmttype to show what type of payment they selected.

Hope this helps.

Leslyn :)
Ooops, my eyes deceived me -- you do have the same name. What browser version are you using?

Leslyn :)
mlcktmguyAuthor Commented:

I am using IE version 6.0.2900.2180.... sp2 version.  I have also tried printing from an old version of Mozilla that I keep around (version 1.4.1) and got the same result.  Figuring that it's a printer issue, I've been in touch with HP tech support, and they claim it is NOT a printer issue:

"I am sorry the radio buttons may not be printed. This since the web
pages are designed with viewing in mind rather than printing.  The
ability to get a successful print depends heavily on the way the page
was constructed and settings within the Web browser.  In most cases,
these issues are due to the way the Web page has been created or
browser issues and have nothing to do with the printer itself.  There
are a number of things that can be done to remedy the situation;
however, there may be times where the print is limited by the browser or
page and cannot be corrected."

They did make a couple of suggestions regarding browser settings, but those changes didn't help.

That is very bizarre.

What do you get when you print out this page, exactly?
mlcktmguyAuthor Commented:

When I printed that form (using my hp officejet d145 and IE6) in the link you supplied, I see everything as it ought to be other than the radio buttons.  The textbox, textarea, checkbox & dropdown box, and their contents, print just fine.  I see the words 'Yes' and 'NO' next to where the radio buttons should appear, however I do not see the buttons themselves.

I agree, this whole thing is *very* bizarre.  :-)
Does this work?
Do FN + Print Screen. Save it in a doc file and print it from there.

Well, Print Screen would be a graphic - not a Browser Object, so I'm not sure how that would lead to the cause exactly.

I've been searching up and down and find no reference to this ever happening before.
I don't suppose there's a big switch on the back of your printer labelled "Don't Print Radio Buttons" ?
I have a user who is having this same problem with an HP printer.  Our application will print fine to any other printer but this HP printer is causing her problems,  
 mlcktmguy, did you ever get this resolved??
mlcktmguyAuthor Commented:
Not really.  We verified that is defintely printer specific.  We have avoided radio buttons on html forms since then for just that reason.  If you come up with anything more please let me know.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.