Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Print Sticky Labels


gregy

Recommended Posts

Hi!

 

Great great great contribution for labels !!!

 

now to the problems :)

 

i have three orders (of course testing) with three different customers .. all i get is to print out only first customers into pdf file ... i don't get it .. CHMOD is ok ..

 

did anybody tried this?

 

thanx

Link to comment
Share on other sites

Hi!

 

Great great great contribution for labels !!!

 

now to the problems :)

 

i have three orders (of course testing) with three different customers .. all i get is to print out only first customers into pdf file ... i don't get it .. CHMOD is ok ..

 

did anybody tried this?

 

thanx

 

 

forget it .. IE and famous CACHE :) .. in Mozilla everything works fine :thumbsup: once again .. great contribution

Link to comment
Share on other sites

Yes, it works (simple install).

 

I found it a bit cumbersome though having to load up Acrobat Reader every time I wanted to print a label. When I print out sticky labels using packingslip.php it just prints normally which is a lot simpler. I wonder why it was done that way.

 

I have a Dymo labelwriter installed (which I use for Royal Mail Smartstamp) and found I was able to print the sticky labels using that with this contribution.

 

What would be useful would be to have the order number printed underneath the address ont he label in a smaller font - helps enormously when trying to keep track of your parcels.

Link to comment
Share on other sites

Yes, it works (simple install).

 

I found it a bit cumbersome though having to load up Acrobat Reader  every time I wanted to print a label.  When I print out sticky labels using packingslip.php it just prints normally which is a lot simpler. I wonder why it was done that way.

 

I have a Dymo labelwriter installed (which I use for Royal Mail Smartstamp) and found I was able to print the sticky labels using that with this contribution.

 

What would be useful would be to have the order number printed underneath the address ont he label in a smaller font - helps enormously when trying to keep track of your parcels.

 

 

hmm .. also would be grat if we could change position of name surname and street etc.

 

i.e. in my country post office rules requires adress on envelope like this

 

Doe John

Street 6

 

3000 City

 

which means

 

Surname Name

Street

"blank line"

Zip City

 

any idea where to handle this?

 

p.s. in contrib section i miss contact with author :)

Link to comment
Share on other sites

Yes, it works (simple install).

 

I found it a bit cumbersome though having to load up Acrobat Reader  every time I wanted to print a label.  When I print out sticky labels using packingslip.php it just prints normally which is a lot simpler. I wonder why it was done that way.

 

I have a Dymo labelwriter installed (which I use for Royal Mail Smartstamp) and found I was able to print the sticky labels using that with this contribution.

 

What would be useful would be to have the order number printed underneath the address ont he label in a smaller font - helps enormously when trying to keep track of your parcels.

 

Hi David,

 

I tried to modify the code to avoid using pdf but I failed :'( . Could you post the modifications you made ?

 

Thanks a lot!

 

mujina

OSC2.2

Link to comment
Share on other sites

Hi David,

 

I tried to modify the code to avoid using pdf but I failed :'(  . Could you post the modifications you made ?

 

Thanks a lot!

 

mujina

 

For hansmignon :

 

Here's what radders explained to me :

 

"My file should require no changes to any other files to just get it working - print a packing slip then change the word 'packingslip' in the url to the name of my file, keeping the rest of the url unchanged."

 

It works thanks to radders!!! :D

OSC2.2

Link to comment
Share on other sites

I should probably mention that the files I used to create a single address label and a returns label using the Dymo labelwriter310 look like this:

 

<?php
/*
based on
$Id: invoice.php,v 1.4 2003/02/16 13:40:33 thomasamoulton Exp $

osCommerce, Open Source E-Commerce Solutions
http://www.oscommerce.com

Copyright (c) 2002 osCommerce

Released under the GNU General Public License
*/

require('includes/application_top.php');

require(DIR_WS_CLASSES . 'currencies.php');
$currencies = new currencies();

$oID = tep_db_prepare_input($HTTP_GET_VARS['oID']);
$orders_query = tep_db_query("select orders_id from " . TABLE_ORDERS . " where orders_id = '" . tep_db_input($oID) . "'");

include(DIR_WS_CLASSES . 'order.php');
$order = new order($oID);
?>
<!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN">
<html <?php echo HTML_PARAMS; ?>>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=<?php echo CHARSET; ?>">
<title>Label Print: Order <?php echo $oID; ?></title>
<link rel="stylesheet" type="text/css" href="includes/stylesheet_label.css">
</head>
<body marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0" bgcolor="#FFFFFF">

<!-- body_text //-->

  <table border="0" width="300" cellspacing="0" cellpadding="2">

       <tr><td class="minuteText">  <?php echo str_replace("\n",", ",STORE_NAME_ADDRESS); ?><br><br>   </td></tr>
      <tr><td class="labelText">  <b><?php echo eregi_replace ("United Kingdom","",tep_address_format($order->delivery['format_id'], $order->delivery, 1, '', '<br>'));  ?>
</td></tr>
      <tr><td class="minuteText" align="right"> Order # <?php echo $oID; ?></td></tr>
      </table>
       <DIV style="page-break-before:always">
       <table border="0" width="300" cellspacing="0" cellpadding="2">

       <tr><td class="minuteText">  <?php echo eregi_replace (", United Kingdom","",tep_address_format($order->delivery['format_id'], $order->delivery, 1, '', ', ')); ?><br><br>   </td></tr>
      <tr><td class="labelText">  <b><?php echo nl2br(STORE_NAME_ADDRESS);  ?>
</td></tr>
      <tr><td class="minuteText" align="right"> Returns # <?php echo $oID; ?></td></tr>
      </table>

<!-- body_text_eof //-->



</body>
</html>
<?php require(DIR_WS_INCLUDES . 'application_bottom.php'); ?>

Using this for the stylesheet. Manually you need to set up the Labelwrite to use the right paper and to print in Landscape format. If you use Firefox you may have to select 'Landscape' in print preview before you print for the first time.

 

/*
 $Id:l stylesheet_label.css, based on v 1.26 2003/06/30 20:03:50 hpdl Exp $

 osCommerce, Open Source E-Commerce Solutions
 http://www.oscommerce.com

 Copyright (c) 2002 osCommerce

 Released under the GNU General Public License
The @page statements actually have no effect as there is virtually no browser support for them but that is how I thought is should work.
*/

body { background-color: #ffffff; color: #000000; margin: 0px; }
@page {size:88mm 35mm;}
@page {size:landscape;}
.labelText { font-family: Verdana, Arial, sans-serif; font-size: 8pt; }
.minuteText { font-family: Verdana, Arial, sans-serif; font-size: 5pt; }
}

 

One other thing to mention. There is some code in there to remove the country name if it is 'United Kingdom'.

Edited by radders
Link to comment
Share on other sites

  • 2 weeks later...

Greetings all,

 

This is an 'ace' contribution, but as ever, I would like to modify it.

 

- I would prefer the order number underneath the name and address, instead of on top, and to show my store name next to it.

 

- Underneath the order number and store name, again in the small font size, I would like to print the product type, e.g. 'Book' or 'Book, T-shirt'. I believe this would be useful for Customs clearance for deliveries oversees.

 

I've been tentatively 'experimenting' with the code to achieve the above, but I'm no coder. Any of you brains out there able to help?

 

Shame the contrib author didn't give their details in the zip.

 

Thanks folks

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...