CN102214076A - Method and device for implementing print on Web page - Google Patents
Method and device for implementing print on Web page Download PDFInfo
- Publication number
- CN102214076A CN102214076A CN2010101547101A CN201010154710A CN102214076A CN 102214076 A CN102214076 A CN 102214076A CN 2010101547101 A CN2010101547101 A CN 2010101547101A CN 201010154710 A CN201010154710 A CN 201010154710A CN 102214076 A CN102214076 A CN 102214076A
- Authority
- CN
- China
- Prior art keywords
- text information
- applet
- information
- locating information
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Images
Abstract
The invention discloses a method and device for implementing print on a Web page, and belongs to the technical field of network communication. The method comprises the following steps: sending print text information and positioning information to Applet; and sending a print command to the Applet so that the Applet creates a print job according to the print text information and the positioning information and calls a local printer at a client side to print after receiving the print command. The device comprises a transmitting module, a processing module, a second receiving module, a print job creation module and a print job print module. The method and the device provided by the invention have the beneficial effects that the Applet calls the local printer at the client side to print without setting a Web browser, which is suitable for any browser supporting the Applet and improves generality for Web page printing; and meanwhile the print content can be accurately located, thus improving the print effect.
Description
Technical field
The present invention relates to network communications technology field, particularly a kind of method and apparatus of on the Web webpage, realizing printing.
Background technology
Along with the development of the network communications technology, the function of Web (World Wide Web) webpage also from strength to strength, by the Web webpage can browsing pictures, news, inquiry data etc., and can directly printing by the data information of Web webpage with needs.
At present, the printing function that usually calls browser self by JavaScript in the Web webpage prints.
Yet in realizing process of the present invention, the inventor finds that there is following problem at least in prior art:
When JavaScript prints at the printing function that calls browser self, need on browser, carry out the setting of some print parameters such as margin, can't be general, and can't printed contents be positioned, printing effect is poor.
Summary of the invention
In order to improve versatility and the printing effect by the Web printed netpage, the embodiment of the invention provides a kind of method and apparatus of realizing printing on the Web webpage.Described technical scheme is as follows:
A kind of method that on the Web webpage, realizes printing, described method comprises:
Print text information and locating information are sent to Applet;
Send print command to described Applet, make described Applet after receiving described print command, create print job, call the client terminal local printer described print job is printed according to described print text information and described locating information.
A kind of device of on the Web webpage, realizing printing, described device comprises:
Sending module is used for print text information and locating information are sent to Applet;
Processing module, be used for sending print command to described Applet, make described Applet after receiving print command, create print job, call the client terminal local printer described print job is printed according to described print text information and described locating information.
A kind of device of on the Web webpage, realizing printing, described device comprises:
Second receiver module is used to receive print text information, locating information and print command;
The print job creation module is used for after described second receiver module receives print text information, locating information and print command, creates print job according to described print text information and described locating information.
The print job print module is used for calling the client terminal local printer described print job being printed after described print job creation module is created print job.
The beneficial effect of the technical scheme that the embodiment of the invention provides is:
Print by calling Applet operated client local printer, need not the browser of Web is provided with, can be fit to the browser of any support Applet, improved versatility by the Web printed netpage; And can accurately locate print What, improve printing effect.
Description of drawings
Fig. 1 is a kind of method flow diagram of realizing printing on the Web webpage that the embodiment of the invention 1 provides;
Fig. 2 is a kind of method flow diagram of realizing printing on the Web webpage that the embodiment of the invention 2 provides;
Fig. 3 is a kind of apparatus structure synoptic diagram of realizing printing on the Web webpage that the embodiment of the invention 3 provides;
Fig. 4 is that another kind that the embodiment of the invention 3 provides is realized the apparatus structure synoptic diagram printed on the Web webpage;
Fig. 5 is a kind of apparatus structure synoptic diagram of realizing printing on the Web webpage that the embodiment of the invention 4 provides;
Fig. 6 is that another kind that the embodiment of the invention 4 provides is realized the apparatus structure synoptic diagram printed on the Web webpage.
Embodiment
For making the purpose, technical solutions and advantages of the present invention clearer, embodiment of the present invention is described further in detail below in conjunction with accompanying drawing.
Embodiment 1
Referring to Fig. 1, the embodiment of the invention provides a kind of method that realizes printing on the Web webpage, and this method comprises:
101: print text information and locating information are sent to Applet.
102: send print command to Applet, make Applet after receiving print command, create print job, call the client terminal local printer print job of creating is printed according to print text information and locating information.
Further, print text information and locating information are sent to before the Applet, also comprise:
Receive the print command that the user sends.
Further, create print job, specifically comprise according to print text information and locating information:
The elements of a fix according to locating information provides are plotted in print text information on the picture;
Create print job according to the picture of drawing.
Further, print text information and locating information are sent to after the Applet, also comprise:
Applet receives print text information and locating information, and the print text information and the locating information that receive are carried out buffer memory.
The described method that on the Web webpage, realizes printing of the embodiment of the invention, print by calling Applet operated client local printer, need not the browser of Web is provided with, can be fit to the browser of any support Applet, improved versatility by the Web printed netpage; And can accurately locate print What, improve printing effect, and can realize overlapping and beat function, thereby can improve printing effect, the loss of reduction printer, saving printing cost further.In addition, can carry out buffer memory, can repeatedly print, save the time-write interval printing text message and locating information.
Embodiment 2
Referring to Fig. 2, the embodiment of the invention provides a kind of method that realizes printing on the Web webpage, and this method comprises:
201: the user sends print command by the Web webpage.
Particularly, the user can send print command by clicking print button that the Web webpage provides, print command etc.
The JavaScript of 202:Web webpage receives the print command that the user sends, and print text information and locating information are sent to Applet.
Wherein, print text information specifically can be the information of one piece of article to be printed, information of a pictures etc.Locating information specifically is X, the Y coordinate of each pixel of print text information.Print text information and locating information are embedded among the JavaScript in advance.And Applet is embedded in the Web webpage in advance, and most browsers all support or support the Applet technology by plug-in unit, thus by Applet can compatible all support Applet browser.Can adopt any feasible method in the prior art particularly, realize print text information and locating information are embedded among the JavaScript, and realize Apple is embedded in the Web webpage.
203:Applet receives print text information and locating information, and the print text information and the locating information that receive are carried out buffer memory.
Need to prove, carry out buffer memory to printing text message and locating information, can repeat repeatedly to print, realize printing the purpose of many information, save the time-write interval by Apple.
204:JavaScript sends print command to Applet, and Applet creates print job according to print text information and locating information after receiving print command, call the client terminal local printer print job of creating is printed.
Particularly, Applet is after receiving print command, the elements of a fix that provide according to locating information with print text information accurate Drawing on picture, and create corresponding print job according to the picture of drawing, Applet is after creating print job, call the client terminal local interface, the tabulation of display client local printer, the user can select arbitrary printer that print job is printed from the client terminal local list of Printers that shows.Can adopt particularly that any feasible method realizes creating print job according to the picture of drawing in the prior art.
Need to prove, call Applet operated client local printer by JavaScript and print, can accurately locate, therefore, can realize that by the described method of the embodiment of the invention cover beats function.So-called cover is beaten function and is meant has been printed with the part general information on printer paper, when printing, only needs particular data is printed to the ad-hoc location of printer paper, and this printing type can improve printing effect, reduces the printer loss, save the printing cost.
The described method that on the Web webpage, realizes printing of the embodiment of the invention, calling Applet operated client local printer by JavaScript prints, need not the browser of Web is provided with, the browser that can be fit to any support Applet has improved the versatility by the Web printed netpage; And can accurately locate print What, improve printing effect, and can realize overlapping and beat function, thereby can improve printing effect, the loss of reduction printer, saving printing cost further.In addition, can carry out buffer memory, can repeatedly print, save the time-write interval printing text message and locating information.
Embodiment 3
Referring to Fig. 3, the embodiment of the invention provides a kind of device of realizing printing on the Web webpage, and this device comprises:
Sending module 301 is used for print text information and locating information are sent to Applet.
Further, referring to Fig. 4, this device also comprises:
Need to prove, print, can accurately locate, therefore, can realize that by the described device of the embodiment of the invention cover beats function by calling Applet operated client local printer.So-called cover is beaten function and is meant has been printed with the part general information on printer paper, when printing, only needs particular data is printed to the ad-hoc location of printer paper, and this printing type can improve printing effect, reduces the printer loss, save the printing cost.
The described device of on the Web webpage, realizing printing of the embodiment of the invention, print by calling Applet operated client local printer, need not the browser of Web is provided with, can be fit to the browser of any support Applet, improved versatility by the Web printed netpage; And can accurately locate print What, improve printing effect, and can realize overlapping and beat function, thereby can improve printing effect, the loss of reduction printer, saving printing cost further.
Embodiment 4
Referring to Fig. 5, the embodiment of the invention provides a kind of device of realizing printing on the Web webpage, and this device comprises:
Print job creation module 402 is used for after second receiver module 401 receives print text information, locating information and print command, creates print job according to print text information and locating information.
Print job print module 403 is used for calling the client terminal local printer print job of creating being printed after print job creation module 402 is created print job.
Further, print job creation module 402 specifically comprises:
The picture drawing unit is used for after second receiver module 401 receives print text information, locating information and print command, and the elements of a fix according to locating information provides are plotted in print text information on the picture.
The print job creating unit is used for after the picture drawing unit is plotted in print text information on the picture, creates print job according to the picture of drawing.
Further, referring to Fig. 6, this device also comprises:
Cache module 404 is used for after second receiver module 401 receives print text information and locating information, and the print text information and the locating information that receive are carried out buffer memory.
Need to prove that the described device of the embodiment of the invention can accurately be located, therefore, can realize that by the described device of the embodiment of the invention cover beats function.So-called cover is beaten function and is meant has been printed with the part general information on printer paper, when printing, only needs particular data is printed to the ad-hoc location of printer paper, and this printing type can improve printing effect, reduces the printer loss, save the printing cost.
The described device of realizing printing on the Web webpage of the embodiment of the invention need not the browser of Web is provided with, and can be fit to this apparatus's browser of any support, has improved the versatility by the Web printed netpage; And can accurately locate print What, improve printing effect, and can realize overlapping and beat function, thereby can improve printing effect, the loss of reduction printer, saving printing cost further.
All or part of content in the technical scheme that above embodiment provides can realize that its software program is stored in the storage medium that can read by software programming, storage medium for example: the hard disk in the computing machine, CD or floppy disk.
The above only is preferred embodiment of the present invention, and is in order to restriction the present invention, within the spirit and principles in the present invention not all, any modification of being done, is equal to replacement, improvement etc., all should be included within protection scope of the present invention.
Claims (9)
1. method of realize printing on the Web webpage is characterized in that described method comprises:
Print text information and locating information are sent to Applet;
Send print command to described Applet, make described Applet after receiving described print command, create print job, call the client terminal local printer described print job is printed according to described print text information and described locating information.
2. the method for realize printing on the Web webpage according to claim 1 is characterized in that, described print text information and locating information is sent to before the Applet, also comprises:
Receive the print command that the user sends.
3. the method that realizes printing on the Web webpage according to claim 1 is characterized in that, and is described according to described print text information and described locating information establishment print job, specifically comprises:
The elements of a fix according to described locating information provides are plotted in described print text information on the picture;
Create print job according to the picture of drawing.
4. according to claim 2 or the 3 described methods of on the Web webpage, realize printing, it is characterized in that, print text information and locating information sent to after the Applet, also comprise:
Described Applet receives described print text information and described locating information, and the described print text information and the described locating information that will receive are carried out buffer memory.
5. device of realize printing on the Web webpage is characterized in that described device comprises:
Sending module is used for print text information and locating information are sent to Applet;
Processing module, be used for sending print command to described Applet, make described Applet after receiving print command, create print job, call the client terminal local printer described print job is printed according to described print text information and described locating information.
6. the device of realizing printing on the Web webpage according to claim 5 is characterized in that described device also comprises:
First receiver module is used for receiving the print command that the user sends before described sending module sends to Applet with print text information and locating information.
7. device of realize printing on the Web webpage is characterized in that described device comprises:
Second receiver module is used to receive print text information, locating information and print command;
The print job creation module is used for after described second receiver module receives print text information, locating information and print command, creates print job according to described print text information and described locating information;
The print job print module is used for calling the client terminal local printer described print job being printed after described print job creation module is created print job.
8. the device of realizing printing on the Web webpage according to claim 7 is characterized in that described print job creation module specifically comprises:
The picture drawing unit is used for after described second receiver module receives print text information, locating information and print command, and the elements of a fix according to described locating information provides are plotted in described print text information on the picture;
The print job creating unit is used for after described picture drawing unit is plotted in described print text information on the picture, creates print job according to described picture.
9. according to claim 7 or the 8 described devices of on the Web webpage, realizing printing, it is characterized in that described device also comprises:
Cache module is used for after described second receiver module receives print text information and locating information, and the described print text information and the described locating information that receive are carried out buffer memory.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN2010101547101A CN102214076A (en) | 2010-04-02 | 2010-04-02 | Method and device for implementing print on Web page |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN2010101547101A CN102214076A (en) | 2010-04-02 | 2010-04-02 | Method and device for implementing print on Web page |
Publications (1)
Publication Number | Publication Date |
---|---|
CN102214076A true CN102214076A (en) | 2011-10-12 |
Family
ID=44745400
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN2010101547101A Pending CN102214076A (en) | 2010-04-02 | 2010-04-02 | Method and device for implementing print on Web page |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN102214076A (en) |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104423903A (en) * | 2013-09-07 | 2015-03-18 | 镇江金软计算机科技有限责任公司 | Method for realizing continuous printing based on B/S (Browser/Server) structure system |
CN106020743A (en) * | 2016-05-10 | 2016-10-12 | 董学振 | A system and a method facilitating user self-service printing |
CN106528006A (en) * | 2015-09-10 | 2017-03-22 | 阿里巴巴集团控股有限公司 | Page printing method and device |
CN107608640A (en) * | 2016-07-12 | 2018-01-19 | 顺丰速运有限公司 | Bluetooth print preview method |
CN108268223A (en) * | 2018-01-15 | 2018-07-10 | 合肥盈云信息科技有限公司 | Method of printing and word depghi based on HTTP data transmissions |
CN111124323A (en) * | 2019-12-18 | 2020-05-08 | 山东浪潮通软信息科技有限公司 | Realization method for calling client printer interface based on Applet mode |
Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101571793A (en) * | 2009-04-24 | 2009-11-04 | 广州市易票联电子商务有限公司 | Method and device for printing page information and control |
-
2010
- 2010-04-02 CN CN2010101547101A patent/CN102214076A/en active Pending
Patent Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101571793A (en) * | 2009-04-24 | 2009-11-04 | 广州市易票联电子商务有限公司 | Method and device for printing page information and control |
Non-Patent Citations (2)
Title |
---|
《铁路计算机应用》 20050929 刘绍杰 利用Java Applet实现Web客户端打印 126-127 5-9 第13卷, 第10期 * |
刘绍杰: "利用Java Applet实现Web客户端打印", 《铁路计算机应用》, vol. 13, no. 10, 29 September 2005 (2005-09-29), pages 126 - 127 * |
Cited By (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104423903A (en) * | 2013-09-07 | 2015-03-18 | 镇江金软计算机科技有限责任公司 | Method for realizing continuous printing based on B/S (Browser/Server) structure system |
CN106528006A (en) * | 2015-09-10 | 2017-03-22 | 阿里巴巴集团控股有限公司 | Page printing method and device |
CN106528006B (en) * | 2015-09-10 | 2022-05-27 | 菜鸟智能物流控股有限公司 | Page printing method and device |
CN106020743A (en) * | 2016-05-10 | 2016-10-12 | 董学振 | A system and a method facilitating user self-service printing |
CN107608640A (en) * | 2016-07-12 | 2018-01-19 | 顺丰速运有限公司 | Bluetooth print preview method |
CN108268223A (en) * | 2018-01-15 | 2018-07-10 | 合肥盈云信息科技有限公司 | Method of printing and word depghi based on HTTP data transmissions |
CN108268223B (en) * | 2018-01-15 | 2021-01-12 | 安徽七色米信息科技有限公司 | Printing method and printing control based on HTTP data transmission |
CN111124323A (en) * | 2019-12-18 | 2020-05-08 | 山东浪潮通软信息科技有限公司 | Realization method for calling client printer interface based on Applet mode |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US9866992B2 (en) | Communication device | |
CN100481088C (en) | Web page resource issuing method and issuing system | |
US9887742B2 (en) | Communication device | |
JP5953844B2 (en) | TERMINAL DEVICE PROGRAM, TERMINAL DEVICE, AND TERMINAL DEVICE CONTROL METHOD | |
CN102591954B (en) | A kind of browser data load method and device | |
CN102214076A (en) | Method and device for implementing print on Web page | |
EP1895402A3 (en) | Printing system, printing method, and printing program | |
CN107665102A (en) | Method, apparatus, storage medium and the system of mobile print data | |
US20140038518A1 (en) | Communication Device | |
JP2003099231A (en) | Printing from portable electronic device | |
JP2012198760A (en) | Terminal device | |
CN105761123A (en) | Virtual bill preservation method and device | |
CN102752371A (en) | Method for achieving splash on client side and client side | |
CN105278884A (en) | Document printing method and device | |
CN104516890A (en) | Business processing method, business processing device and electronic equipment | |
JP2006252053A (en) | Qr code generation device and generation method, and qr code generation system | |
CN103473035A (en) | Screen capturing method and device | |
CN102368202A (en) | Webpage selectable printing method for mobile terminal based on local area network | |
CN110633443B (en) | Method, device, equipment and medium for intra-page data communication | |
JP4123726B2 (en) | Digital still camera | |
US20050060341A1 (en) | Attachment file processing system and attachment file processing method | |
CN112433687A (en) | Self-service printing/copying method, system and computer readable storage medium | |
JP2007122615A (en) | Information processing system, printer, content access system, program for information processing system, program for printer, and program for content access system | |
JP4609560B2 (en) | Image forming apparatus and printing control method in the image forming apparatus | |
CN109960475A (en) | A kind of Web page printing method and print system |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C12 | Rejection of a patent application after its publication | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20111012 |