The shopping mall system developed in php requires the ability to print delivery orders and express parcels in batches. How to implement this. The current method is to use the browser's built-in printing function to print the web page, display the content on the web page and print it, but how can we ensure that the printed page is reasonable... the shopping mall system developed in php requires the ability to print delivery orders and express parcels in batches. How to implement this.
The current method is to use the browser's built-in printing function to print the webpage, display the content on the webpage, and then print it. but how can we ensure that the printed page is reasonable? Or is there any way?
Reply content:
The shopping mall system developed in php requires the ability to print delivery orders and express parcels in batches. How to implement this.
The current method is to use the browser's built-in printing function to print the webpage, display the content on the webpage, and then print it. but how can we ensure that the printed page is reasonable? Or is there any way?
What the landlord really wants to ask is how to print a pile of data to the parcel list instead of hand writing.
- How to print to a parcel ticket
You can go to some shops to ask, for example, the courier you receive is not hand-written.
The information I just found is as follows:
Http://h10025.www1.hp.com/ewfrf/wc/document? Cc = cn & lc = zh-hans & dlc = zh-hans & docname = c00088990
Http://office.abang.com/od/word/a/envelope.htm
I have never used it, but you can print the envelope or the express order. For other purposes, such as printing tickets with different names (this function should be available in Word, and Microsoft has long thought of it for us ).
If the Word does not have the ability to print the express waybill, but if the Word is well designed, there should be a template function. you should change the envelope to the form of the express waybill. (It is possible that shop owners have such templates)
As you can see, in the above tutorial, Word supports selecting Excel as the data source, so as a PHP mall, you only need to export the address as a regular Excel file. Then let the Word print.
Look at the type of express waybill, usually there are holes on both sides of the express waybill, this is a direct support for dot matrix printer, you can play with it.
@ Carl's answer is that PHP directly calls the printer interface and studies how to print the Word. When PHP generates an order, it calls the interface to generate the data and print it.
Finally, this problem may have been solved by commercial printing software for a long time. We just don't know.
Search results by Google:
Windows:
PHP has a Windows extension named Printer, which uses win32api to call the system Printer service.
You can print formatted documents and reports, and draw simple images to print images.
Sample code:
Materials: http://phpstarter.net/2010/05/send-print-jobs-directly-from-php/
Unix/Linux:
Availablesystem()
Function calllpr
The tool connects to the printing server to complete printing.
Materials: http://linux.about.com/library/cmd/blcmdl1_lpr.htm
Php pdf file generation extension: http://www.php.net/manual/en/book.pdf.php
Direct WEB printing can be controlled using css:
Css for screen display:
Css used for printing:
We recommend that you use controls to make them easier to control.