Forum Moderators: phranque

Message Too Old, No Replies

Avery Labels

how to...

         

grandpa

6:36 am on Jan 11, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



I use a publishing program to create product labels on a standard Avery address label - 2in x 4in. Each label is customized for a given product.. that is to say I add a text box on top of an image file and print.

I would like to develop a program that will generate these labels based upon the content of any particular order. Let's say my customer ordered 2 each of Product A, 1 each of Product B and 1 each of Product C. On my Admin panel, I'll have a screen showing this customers order number, and when selected, the correct labels for each of the products will be generated and the entire print job (all labels for the order) would then be submitted to the local printer.

I've been looking around at SourceForge and Zend for something that will do this, but I'm feeling kinda outnumbered.. so what I'm asking is if someone can point me in the right direction.

A less elegant approach might be to create each individual label, and have them stored in a database as an image. Then I could simply pick and choose from the database. The information I lack for this approach is how to generate a template on the fly (for the Avery label), and send this to my printer from a web based application.

Any direction to solving this would be greatly appreciated.

gracias

grandpa

8:57 am on Jan 11, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Bah! Too easy. Sorry you had to jump in here and read this for nothing ;)

I created a document, labels.htm. It contains a 2 column table, to correspond with my two column form. I populated the table with text and images.

The php script is avery1.php, and contains 3 lines:
<?php
header ("Content-type: application/msword");
header ("Content-Disposition: attachment; filename=report.doc");
include('labels.htm');
?>

It's a simple process to create report.doc in Word, using an Avery template.

Execute the script, and Word opens "report.doc" ready to print. The hard part was finding a reference for it out there... The fun part can begin now. labels.htm will have to be dynamically generated. That leaves me to try to create labels on the fly, using a basic Tiff image and adding text - or to retrieve individual labels, stored as images, from a database. Any thoughts on which might be better and why?

And, someone still has to load forms in the printer. Oh well.

txbakers

2:57 pm on Jan 11, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I do all kinds of labels directly from the browser, in HTML, without using Word.

It takes quite a bit of tweaking and absolute positioning, and the user has to do some page setup before printing them, but when all this is done, it works great!

I have about 5 different templates right now, including the 3 across 10 down mailing label, which is the most used.

grandpa

6:33 pm on Jan 11, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



...It takes quite a bit of tweaking and absolute positioning...

Even as I've just begun this project I can see where three different templates would be useful. Should I assume that your documents are dynamically generated, and that you rely heavily on CSS for the positioning? Using Word isn't a problem, today. But tomorrow we could be using a system without MS (can't a fellow dream?). Printing directly from the browser is appealing.

I still have a question (in my mind) about these images of mine. It's still early on, and I hope I can find a way to place a text box on my image. Otherwise I'll have to create thousands of unique images; not something to relish.

txbakers

8:02 pm on Jan 11, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Yes, I rely heavily on absolute positioning CSS to make it work.

I don't use images, and all the pages are dynamically generated with the information requested by the user.

It's really quite a comprehensive label request page.

jollymcfats

11:21 pm on Jan 11, 2005 (gmt 0)

10+ Year Member



I've been looking around at SourceForge and Zend for something that will do this

I've looked around for this too, and I ended up leaning towards PDF. It looks pretty easy to build PDF label templates with the R&OS PDF class. No futzing with print settings needed with a PDF.

My label project is still languishing on my todo list, but I'm planning on giving it a go in PDF when the time comes.

vkaryl

12:57 am on Jan 15, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



WordPerfect comes standard with tons of Avery Label templates built in. Even the "weird" ones - round, oval, and teensy-tiny ones....

I use WP for everything templatish - with RevealCodes active on your pages, you never have to guesstimate.

olwen

1:02 am on Jan 15, 2005 (gmt 0)

10+ Year Member



I've looked around for this too, and I ended up leaning towards PDF. It looks pretty easy to build PDF label templates with the R&OS PDF class. No futzing with print settings needed with a PDF.

I've used exactly that approach for a project that needs strict formatting.

txbakers

3:21 am on Jan 15, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



How do you read from the database, populate a WP file and deliver it across the web?

vkaryl

4:02 pm on Jan 15, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Don't know; never tried it; don't need that functionality. I figure it's possible, but I wouldn't have a clue how - though even my docs on 9 (which is now antique of course) discuss that sort of thing....

grandpa

9:41 am on Jan 24, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



It takes quite a bit of tweaking and absolute positioning, and the user has to do some page setup before printing them, but when all this is done, it works great!

I tried PDF, and ended up designing my layout with CSS. I couldn't get page breaks to work at all! Maybe later... for now I let you print one page, and let you pick a start position on that page. If there are more labels, select buttons will let you print those. Another feature is the ability to select any one label, and print in any location on the form. With a little page setup, as previously mentioned, we can print an order number on the edge of the form.

Now all that remains is to print shipping labels and set up more product labels.
Thanks for all the ideas. I'm dang near a hero again, and I owe it all back here. The next round's on me.