Re: printing for dot matrix printers



On 1/15/2011 6:29 PM, Robert Heller wrote:
At Sat, 15 Jan 2011 16:59:47 -0500 Jerry Stuckle<jstucklex@xxxxxxxxxxxxx> wrote:


On 1/15/2011 4:11 PM, 24saat wrote:
Hi

I'm looking a solutions dotmatrix printer solution for php.
I need print a form or invoice to dotmatrix printer in browser.


Thanks

Ertan
php and asp.net developer
symfony& kohana specialist
http://www.webtasarimsitesi.com

Your best bet is probably to create a pdf and print that.

If it is going to a *web browser*, just send simple HTML (eg, not fun
and games with iframes and whatnot), include a .css file with '@media
print' rules. All major web browser know how to print a web page to
whatever passes as the local printer. So long as the stylesheet's
'@media print' rules are reasonably generic and don't play excessive
games with fonts and so long as the page to be printed is not 'colorful'
and is without images, it should be possible for the web browser to send
it to any sort of printer without too much trouble and with a reasonable
faithfulness to the formatting.




Simply because different browsers and different printers will print the same file different ways. HTML is, after all, only a *guide*.

If you want to ensure it prints in the way you want it to (as in an invoice), pdf is the way to go. It doesn't suffer those problems.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex@xxxxxxxxxxxxx
==================
.



Relevant Pages

  • Re: printing for dot matrix printers
    ... I'm looking a solutions dotmatrix printer solution for php. ... I need print a form or invoice to dotmatrix printer in browser. ... If it is going to a *web browser*, just send simple HTML (eg, not fun ...
    (comp.lang.php)
  • Re: The Inquirer
    ... >>I could write a compiler for an arbitrary language and put this to open ... > Now go to the url with whatever web browser your using. ... PHP is open source. ... that the actual source code that makes ...
    (comp.os.vms)
  • [Full-Disclosure] Re: Advanced XSS paper and semi-new attack
    ... * Many environments (PHP, Perl+CGI.pm) accept both POSTed and GETted data. ... browser start fetching a URL as soon as the web browser sees it, ... server but which immediately redirects to a mail sending script at your server. ...
    (Full-Disclosure)
  • Re: how to run scripts after a page has already loaded and been sent to a users browser?
    ... It's because PHP is a server side scripting language, ... do stuff before you send stuff to user's web browser. ... > echo "Here is the number of times this page has been viewed: ...
    (alt.php)
  • Re: Access linux server from window
    ... > Right now I can't run php program on my machine. ... > web browser only get wrong message. ... html mail or attachments will go in the spam ...
    (comp.os.linux.misc)