Results 1 to 6 of 6

SHIPPING LABEL VIA PDF w/ oscmax 2.0

This is a discussion on SHIPPING LABEL VIA PDF w/ oscmax 2.0 within the osCmax v2 Customization/Mods forums, part of the osCmax v2.0 Forums category; Hi - I've installed SHIPPING LABEL VIA PDF 10 Jul 2008 version into my oscmax 2.0 site. When I click ...

      
  1. #1
    Active Member
    Join Date
    Aug 2004
    Posts
    117
    Rep Power
    0


    Default SHIPPING LABEL VIA PDF w/ oscmax 2.0

    Hi -

    I've installed SHIPPING LABEL VIA PDF 10 Jul 2008 version into my oscmax 2.0 site. When I click on the label button, I receive the following message: "Access Denied: No Right Permission Access Please contact your Web Administrator to request more access or if you found any problem."

    What do I need permission access to? I have uploaded the fpdf.php file. The directions do not say anything about changing permissions on any files or directories.

    Thanks for the help.
    Barb

  2. #2
    Active Member
    Join Date
    Aug 2004
    Posts
    117
    Rep Power
    0


    Default Re: SHIPPING LABEL VIA PDF w/ oscmax 2.0

    I found the solution. I had to go under Administrator -- File access and add the label_pdf.php file under "customers"

  3. #3
    Active Member
    Join Date
    Aug 2004
    Posts
    117
    Rep Power
    0


    Default Re: SHIPPING LABEL VIA PDF w/ oscmax 2.0

    I've purchased a Dymo LabelWriter 400 Turbo and hooked it up to my computer. When I try to print my label from oscmax the addresses don't fit. I'm using 2 1/8" (54mm) x 4" (102mm) shipping labels. I click on "label" and then see the pdf file that is created. I then select -- file, print and select the dymo labelwriter printer. In the print window, I'm shown that the document is 4 x 2.1 in and then under that I see the paper is listed 1.1 x 3.5 in. Why the difference in sizes?

    I've set size to equal the mm size of the labels:

    $pdf=new FPDF('L','mm',array(54, 102));


    My label_pdf.php file looks like this:

    <?php
    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 = '" . (int)$oID . "'");
    include(DIR_WS_CLASSES . 'order.php');
    $order = new order($oID);
    function tep_dr($address_format_id, $address, $html, $boln, $eoln) {
    $address_format_query = tep_db_query("select address_format as format from " . TABLE_ADDRESS_FORMAT . " where address_format_id = '" . (int)$address_format_id . "'");
    $address_format = tep_db_fetch_array($address_format_query);
    $company = tep_output_string_protected($address['company']);
    if (isset($address['firstname']) && tep_not_null($address['firstname'])) {
    $firstname = tep_output_string_protected($address['firstname']);
    $lastname = tep_output_string_protected($address['lastname']);
    } elseif (isset($address['name']) && tep_not_null($address['name'])) {
    $firstname = tep_output_string_protected($address['name']);
    $lastname = '';
    } else {
    $firstname = '';
    $lastname = '';
    }
    $street = tep_output_string_protected($address['street_address']);
    $suburb = tep_output_string_protected($address['suburb']);
    $city = tep_output_string_protected($address['city']);
    $state = tep_output_string_protected($address['state']);
    if (isset($address['country_id']) && tep_not_null($address['country_id'])) {
    $country = tep_get_country_name($address['country_id']);
    if (isset($address['zone_id']) && tep_not_null($address['zone_id'])) {
    $state = tep_get_zone_code($address['country_id'], $address['zone_id'], $state);
    }
    } elseif (isset($address['country']) && tep_not_null($address['country'])) {
    $country = tep_output_string_protected($address['country']);
    } else {
    $country = '';
    }
    $postcode = tep_output_string_protected($address['postcode']);
    $zip = $postcode;
    $line1= "$firstname $lastname";
    $line2= "$company";
    $line3="$street";
    $line4="$city" . ', ' . "$state $zip";
    $line5="$country";
    define('FPDF_FONTPATH','font/');
    require('fpdf.php');
    $pdf=new FPDF('L','mm',array(54, 102));
    $pdf->AddPage();
    $pdf->SetXY('4', '4');
    $pdf->SetMargins('0','0','0');
    $pdf->SetFont('Arial','Bi',10);
    $pdf->Cell(80,4,'The Map Shop',0,1);
    $pdf->SetX('4');
    $pdf->Cell(80,4,'Northfield Commons',0,2);
    $pdf->Cell(80,4,'50 State Street',0,2);
    $pdf->Cell(80,4,'Pittsford, NY 14534',0,2);
    $pdf->Cell(70,4,'',T,1);
    $pdf->SetX(35);
    $pdf->SetFont('Arial','',10);
    $pdf->Cell(40,4,' ',0,2);
    $pdf->Cell(40,4,"$line1",0,2);
    if($line2 != ''){
    $pdf->Cell(40,4,"$line2",0,2);
    }
    $pdf->Cell(40,4,"$line3",0,2);
    $pdf->Cell(40,4,"$line4",0,2);
    if($line5 != 'United States'){
    $pdf->Cell(40,4,"$line5",0,2);
    }
    $pdf->Output();
    if ($html) {
    // HTML Mode
    $HR = '<hr>';
    $hr = '<hr>';
    if ( ($boln == '') && ($eoln == "\n") ) { // Values not specified, use rational defaults
    $CR = '<br>';
    $cr = '<br>';
    $eoln = $cr;
    } else { // Use values supplied
    $CR = $eoln . $boln;
    $cr = $CR;
    }
    } else {
    // Text Mode
    $CR = $eoln;
    $cr = $CR;
    $HR = '----------------------------------------';
    $hr = '----------------------------------------';
    }
    $statecomma = '';
    $streets = $street;
    if ($suburb != '') $streets = $street . $cr . $suburb;
    if ($country == '') $country = tep_output_string_protected($address['country']);
    if ($state != '') $statecomma = $state . ', ';

    $fmt = $address_format['format'];
    eval("\$address = \"$fmt\";");

    if ( (ACCOUNT_COMPANY == 'true') && (tep_not_null($company)) ) {
    $address = $company . $cr . $address;
    }
    }
    tep_dr($order->delivery['format_id'], $order->delivery, 1, '', '<br>');
    ?>
    <?php require(DIR_WS_INCLUDES . 'application_bottom.php'); ?>

    Thanks for the help.
    Barb

  4. #4
    Active Member MindTwist's Avatar
    Join Date
    Jun 2007
    Location
    Barcelona, Spain
    Posts
    408
    Rep Power
    7


    Default Re: SHIPPING LABEL VIA PDF w/ oscmax 2.0

    Quote Originally Posted by basnyd View Post
    When I try to print my label from oscmax the addresses don't fit.
    That has nothing to do with OSCMAX, but with your printer config, how that module is creating the labels, etc. and is hardly something anything except yourself can fix, since we do not have access to your printer, your labels, your printer drivers configuration...

    Btw, OSCMAX comes with Batch Print Center, I use it for printing my labels amongst other things, and it works great once you have created your templates.

  5. #5
    Active Member
    Join Date
    Aug 2004
    Posts
    117
    Rep Power
    0


    Default Re: SHIPPING LABEL VIA PDF w/ oscmax 2.0

    I understand you don't have access to my printer or it's configuration. I was asking the question in case someone had used this printer and had some advice on how to get everything working. I did get some help from the DYMO company and everything is now working smoothly.

    BTW - I never knew that Batch Print Center was already installed. Right now Batch Print Center is throwing a couple error messages. I'll have to track those down and see if I can get it to work also.

    One thing that I like about the Shipping Label via PDF option is that you can operate it directly from the order screens and you don't have to go to a separate area to print the labels.

  6. #6
    Active Member MindTwist's Avatar
    Join Date
    Jun 2007
    Location
    Barcelona, Spain
    Posts
    408
    Rep Power
    7


    Default Re: SHIPPING LABEL VIA PDF w/ oscmax 2.0

    That sounds nice.

    As I can tell from my experience printing labels/PDFs, how it comes out has nothing to do with OSCMAX. There are many settings on the printer, the driver, Acrobat Reader, etc. When you print you even have one option to stretch the PDF, rotate it, bla bla... So even if you have created a PDF that is the exact same size of your labels, it might not print exactly like that.

    So it is just a matter of trial and error, and waste a few pages/labels until you get the exact size you are looking for.

Similar Threads

  1. Shipping label via pdf
    By michael_s in forum New osCommerce Contributions
    Replies: 0
    Last Post: 07-10-2008, 02:11 AM
  2. Print all shipping label WITHOUT open any order detail page?
    By kepin in forum osCmax v2 Customization/Mods
    Replies: 3
    Last Post: 07-05-2007, 09:48 PM
  3. No FedEx Shipping Label
    By torweb in forum osCMax v2 Features Discussion
    Replies: 4
    Last Post: 08-25-2006, 03:34 PM
  4. USPS Label Contribution/Program
    By stewj1 in forum osCmax v1.7 Discussion
    Replies: 1
    Last Post: 01-02-2005, 11:34 PM
  5. Custom Label Store
    By haribole in forum osCommerce 2.2 Modification Help
    Replies: 1
    Last Post: 05-26-2003, 03:02 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •