Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

problems getting macintosh to print

Status
Not open for further replies.

emmdee

Technical User
May 25, 2003
3
AU
I'm using bignosebird form script (perl)for an order form. I've included a simple javascript print script in the
HTML section of the Thankyou page (which fills in the details of the order for the punter..I want them to be able to print it ...see below...Now here's the wierdness..
the page prints fine on a pc but not on a Mac...anyone got any clues??
Regards emmdee
>>>...............sample script......
sub thank_you
{
print "Content-type: text/html\n\n";
print <<__W2__;
<BODY BGCOLOR=&quot;FFFFCC&quot;><CENTER>
<TABLE WIDTH=550 BORDER=1>
<TR >
<TD align =&quot;center&quot;>
<b>
<H1>THANK YOU FOR YOUR ORDER!</H1>
Your information has been sent and will be processed as soon as possible.<br>
Click
<a href='javascript:;' onClick='window.print();return false'>HERE</a> to Print.
<BR>
Here is the information you provided:<BR>
__W2__foreach $itm (@sortlist) {
.....................etc etc ......
 
what do u mean doesnt print? does the print command does not execute at all? or the print executes but the paper is blank?

Known is handfull, Unknown is worldfull
 
Hi there
I mean that when the link is clicked nothing happens..zero zilch...however I think the problem is the space between ' and javascript in the code...
<a href=' javascript:;' onClick='window.print();return false'>HERE</a>....
windows would wear it, but i believe javascript on the mac hates spaces...that's my theory..i havent got a mac, but if anyone has could you test things at I've ftp'd the corrected code.
regds
emmdee
 
try removing the return false; line:
<a href=' javascript:;' onClick='window.print();'>HERE</a>

Known is handfull, Unknown is worldfull
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top