Page 93 of 102 FirstFirst ... 43839192939495 ... LastLast
Results 921 to 930 of 1019
  1. #921
    Join Date
    Jun 2006
    Posts
    298
    Plugin Contributions
    0

    Default Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

    Also had to decode the order status and order comments:

    Code:
                if ($orders_history->RecordCount() > 0) {   
                   while (!$orders_history->EOF) {   
                        if ($orders_history->fields['comments'] != '' && strpos($orders_history->fields['comments'], 'PayPal status:') === false){ 
                            $count_comments++;
                            $pdf->Cell(120, 14, zen_datetime_short($orders_history->fields['date_added']));  
                            $pdf->MultiCell(456, 14, utf8_decode($orders_status_array[$orders_history->fields['orders_status_id']]));                                       
                            $pdf->Cell(27, 14, '', 0, 0, '', 1);
                            $pdf->MultiCell(549, 14, (utf8_decode(zen_db_output($orders_history->fields['comments']))), 'B');  
                            $pdf->SetLineWidth(.5);
                            $pdf->Line(18,$pdf->GetY(),594,$pdf->GetY());                                    
                        } 
                        $orders_history->MoveNext();
                        if (ORDER_COMMENTS_PACKING_SLIP == 1 && $count_comments >= 1) {
                            break;
                        }
                    }       
                }

  2. #922
    Join Date
    Jan 2007
    Location
    Los Angeles, California, United States
    Posts
    10,021
    Plugin Contributions
    32

    Default Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

    Quote Originally Posted by abcisme View Post
    Also had to decode the order status and order comments:

    Code:
                if ($orders_history->RecordCount() > 0) {   
                   while (!$orders_history->EOF) {   
                        if ($orders_history->fields['comments'] != '' && strpos($orders_history->fields['comments'], 'PayPal status:') === false){ 
                            $count_comments++;
                            $pdf->Cell(120, 14, zen_datetime_short($orders_history->fields['date_added']));  
                            $pdf->MultiCell(456, 14, utf8_decode($orders_status_array[$orders_history->fields['orders_status_id']]));                                       
                            $pdf->Cell(27, 14, '', 0, 0, '', 1);
                            $pdf->MultiCell(549, 14, (utf8_decode(zen_db_output($orders_history->fields['comments']))), 'B');  
                            $pdf->SetLineWidth(.5);
                            $pdf->Line(18,$pdf->GetY(),594,$pdf->GetY());                                    
                        } 
                        $orders_history->MoveNext();
                        if (ORDER_COMMENTS_PACKING_SLIP == 1 && $count_comments >= 1) {
                            break;
                        }
                    }       
                }
    To help others it would be useful if you included the approximate line numbers where you made your changes..
    My Site - Zen Cart & WordPress integration specialist
    I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.

  3. #923
    Join Date
    Jun 2006
    Posts
    298
    Plugin Contributions
    0

    Default Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

    Quote Originally Posted by DivaVocals View Post
    To help others it would be useful if you included the approximate line numbers where you made your changes..
    Sorry! Here you go. My store is in French and English, so I needed to specify UTF-8 in order for the French characters to show up correctly. I am sure there must be a better way to specify the default charset for the whole pdf file, but this was the only way I knew how to do it.

    These were the changes I made in admin/includes/functions/extra_functions/lcsd_merged_packing_slips.php

    I have made a LOT of changes to this file, so line numbers are approximate.

    Around line 242:

    Code:
                    $orderText .= utf8_decode( ' ' . $order->products[$i]['qty'] . 'x ' . $order->products[$i]['name'] . '/' . $order->products[$i]['model'] . $attribText);
    Around line 345:

    Code:
        function draw_packing_slip_customer($order, &$pdf){
            $billTo = utf8_decode(zen_address_format($order->customer['format_id'], $order->billing, 0, '', "\n"));
            if($order->billing['street_address'] == ''){
                $billTo = utf8_decode(zen_address_format($order->customer['format_id'], $order->customer, 0, '', "\n"));    
            } 
            
            $shipTo = utf8_decode(zen_address_format($order->delivery['format_id'], $order->delivery, 0, '', "\n")); 
            if($order->delivery['street_address'] == ''){
                $shipTo = utf8_decode(zen_address_format($order->customer['format_id'], $order->customer, 0, '', "\n"));    
            }
    Around line 426:

    Code:
           for ($i=0, $n=sizeof($order->products); $i<$n; $i++) {
                $prod_name = utf8_decode($order->products[$i]['name']);                          
                if (isset($order->products[$i]['attributes']) && (sizeof($order->products[$i]['attributes']) > 0)) {
                    for ($j=0, $k=sizeof($order->products[$i]['attributes']); $j<$k; $j++) {
                        $prod_name .= utf8_decode(' ' . $order->products[$i]['attributes'][$j]['option'] . ': ' . zen_output_string_protected($order->products[$i]['attributes'][$j]['value']));
                    }
    Around line 493:

    Code:
               if ($orders_history->RecordCount() > 0) {   
                   while (!$orders_history->EOF) {   
                        if ($orders_history->fields['comments'] != '' && strpos($orders_history->fields['comments'], 'PayPal status:') === false){ 
                            $count_comments++;
                            $pdf->Cell(120, 14, zen_datetime_short($orders_history->fields['date_added']));  
                            $pdf->MultiCell(456, 14, utf8_decode($orders_status_array[$orders_history->fields['orders_status_id']]));                                       
                            $pdf->Cell(27, 14, '', 0, 0, '', 1);
                            $pdf->MultiCell(549, 14, (utf8_decode(zen_db_output($orders_history->fields['comments']))), 'B');  
                            $pdf->SetLineWidth(.5);
                            $pdf->Line(18,$pdf->GetY(),594,$pdf->GetY());                                    
                        }
    Also, to get rid of hardcoded text and use the define text for multi-language you will need to define ENTRY_PHONE, ENTRY_EMAIL and ENTRY_ORDER_STATUS in admin/includes/languages/YOUR_LANGUAGE/super_batch_forms.php

    Then, in admin/includes/functions/extra_functions/lcsd_merged_packing_slips.php

    Around 359:

    Code:
            $pdf->SetFont('Arial','', 9);    
            $billToY = $pdf->GetY();
            $pdf->MultiCell(220, 13, ENTRY_SOLD_TO . "\n\n" . $billTo); 
            $pdf->Ln(8); 
            $pdf->MultiCell(220, 13, ENTRY_PHONE . ' : ' . $customerPhone); 
            $pdf->MultiCell(220, 13, ENTRY_EMAIL . ' : ' . $customerEmail); 
            $pdf->Ln(6);           
            $EndY = $pdf->GetY();
            $pdf->SetXY(306, $billToY);  
        	$pdf->SetFont('Arial','B', 12);
    		$pdf->MultiCell(220, 13, ENTRY_SHIP_TO . "\n\n" . $shipTo);   
            $pdf->SetXY(18, $EndY);  
        }
    And around line 479:

    Code:
           if (ORDER_COMMENTS_PACKING_SLIP > 0) {                                                                     
                $pdf->Ln();         
                $pdf->SetFillColor(180,180,180);    
                $pdf->SetFont('Arial','B', 10);       
                $pdf->MultiCell(576, 14, ENTRY_ORDER_STATUS . ' ', 'B');   
                $pdf->SetFont('Arial','', 8);      
                $pdf->SetFillColor(256,256,256);
    Last edited by abcisme; 20 Nov 2012 at 12:41 PM.

  4. #924
    Join Date
    Jan 2007
    Location
    Los Angeles, California, United States
    Posts
    10,021
    Plugin Contributions
    32

    Default Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

    To be clear this was all done for SO v3.0 for Zen Cart 1.3.9 correct??
    Quote Originally Posted by abcisme View Post
    Sorry! Here you go. My store is in French and English, so I needed to specify UTF-8 in order for the French characters to show up correctly. I am sure there must be a better way to specify the default charset for the whole pdf file, but this was the only way I knew how to do it.

    These were the changes I made in admin/includes/functions/extra_functions/lcsd_merged_packing_slips.php

    I have made a LOT of changes to this file, so line numbers are approximate.

    Around line 242:

    Code:
                    $orderText .= utf8_decode( ' ' . $order->products[$i]['qty'] . 'x ' . $order->products[$i]['name'] . '/' . $order->products[$i]['model'] . $attribText);
    Around line 345:

    Code:
        function draw_packing_slip_customer($order, &$pdf){
            $billTo = utf8_decode(zen_address_format($order->customer['format_id'], $order->billing, 0, '', "\n"));
            if($order->billing['street_address'] == ''){
                $billTo = utf8_decode(zen_address_format($order->customer['format_id'], $order->customer, 0, '', "\n"));    
            } 
            
            $shipTo = utf8_decode(zen_address_format($order->delivery['format_id'], $order->delivery, 0, '', "\n")); 
            if($order->delivery['street_address'] == ''){
                $shipTo = utf8_decode(zen_address_format($order->customer['format_id'], $order->customer, 0, '', "\n"));    
            }
    Around line 426:

    Code:
           for ($i=0, $n=sizeof($order->products); $i<$n; $i++) {
                $prod_name = utf8_decode($order->products[$i]['name']);                          
                if (isset($order->products[$i]['attributes']) && (sizeof($order->products[$i]['attributes']) > 0)) {
                    for ($j=0, $k=sizeof($order->products[$i]['attributes']); $j<$k; $j++) {
                        $prod_name .= utf8_decode(' ' . $order->products[$i]['attributes'][$j]['option'] . ': ' . zen_output_string_protected($order->products[$i]['attributes'][$j]['value']));
                    }
    Around line 493:

    Code:
               if ($orders_history->RecordCount() > 0) {   
                   while (!$orders_history->EOF) {   
                        if ($orders_history->fields['comments'] != '' && strpos($orders_history->fields['comments'], 'PayPal status:') === false){ 
                            $count_comments++;
                            $pdf->Cell(120, 14, zen_datetime_short($orders_history->fields['date_added']));  
                            $pdf->MultiCell(456, 14, utf8_decode($orders_status_array[$orders_history->fields['orders_status_id']]));                                       
                            $pdf->Cell(27, 14, '', 0, 0, '', 1);
                            $pdf->MultiCell(549, 14, (utf8_decode(zen_db_output($orders_history->fields['comments']))), 'B');  
                            $pdf->SetLineWidth(.5);
                            $pdf->Line(18,$pdf->GetY(),594,$pdf->GetY());                                    
                        }
    Also, to get rid of hardcoded text and use the define text for multi-language you will need to define ENTRY_PHONE, ENTRY_EMAIL and ENTRY_ORDER_STATUS in admin/includes/languages/YOUR_LANGUAGE/super_batch_forms.php

    Then, in admin/includes/functions/extra_functions/lcsd_merged_packing_slips.php

    Around 359:

    Code:
            $pdf->SetFont('Arial','', 9);    
            $billToY = $pdf->GetY();
            $pdf->MultiCell(220, 13, ENTRY_SOLD_TO . "\n\n" . $billTo); 
            $pdf->Ln(8); 
            $pdf->MultiCell(220, 13, ENTRY_PHONE . ' : ' . $customerPhone); 
            $pdf->MultiCell(220, 13, ENTRY_EMAIL . ' : ' . $customerEmail); 
            $pdf->Ln(6);           
            $EndY = $pdf->GetY();
            $pdf->SetXY(306, $billToY);  
            $pdf->SetFont('Arial','B', 12);
            $pdf->MultiCell(220, 13, ENTRY_SHIP_TO . "\n\n" . $shipTo);   
            $pdf->SetXY(18, $EndY);  
        }
    And around line 479:

    Code:
           if (ORDER_COMMENTS_PACKING_SLIP > 0) {                                                                     
                $pdf->Ln();         
                $pdf->SetFillColor(180,180,180);    
                $pdf->SetFont('Arial','B', 10);       
                $pdf->MultiCell(576, 14, ENTRY_ORDER_STATUS . ' ', 'B');   
                $pdf->SetFont('Arial','', 8);      
                $pdf->SetFillColor(256,256,256);
    My Site - Zen Cart & WordPress integration specialist
    I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.

  5. #925
    Join Date
    Jun 2006
    Posts
    298
    Plugin Contributions
    0

    Default Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

    Quote Originally Posted by DivaVocals View Post
    To be clear this was all done for SO v3.0 for Zen Cart 1.3.9 correct??
    Here's what my header says:

    PHP Code:
    /*
    //////////////////////////////////////////////////////////////////////////
    //  SUPER ORDERS v3.0                                                   //
    //                                                                      //
    //  Based on Super Order 2.0                                            //
    //  By Frank Koehl - PM: BlindSide (original author)                    //
    //                                                                      //
    //  Super Orders Updated by:                                            //
    //  ~ JT of GTICustom                                                    //
    //  ~ C Jones Over the Hill Web Consulting (http://overthehillweb.com)    //
    //  ~ Loose Chicken Software Development, [email protected]        //
    //                                                                      //
    //  Powered by Zen-Cart (www.zen-cart.com)                              //
    //  Portions Copyright (c) 2005 The Zen-Cart Team                       //
    //                                                                         //
    //  Released under the GNU General Public License                       //
    //  available at www.zen-cart.com/license/2_0.txt                       //
    //  or see "license.txt" in the downloaded zip                          //
    //////////////////////////////////////////////////////////////////////////
    //  DESCRIPTION:   PDF version of super_packingslip.php,                //
    //  Features include:                                                    //
    //    ~    Pricing information which supports tax included pricing options    //
    //        identical to super_invoices.php                                    //
    //  ~    Admin configurable options to use with forms that have a peel    //
    //        off    mailing label in place of the default "Packing Slip" text    //
    //////////////////////////////////////////////////////////////////////////
    // $Id: super_batch_forms.php v 2010-10-24 $ 

  6. #926
    Join Date
    Jan 2007
    Location
    Los Angeles, California, United States
    Posts
    10,021
    Plugin Contributions
    32

    Default Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

    Awesome!!! Thanks for sharing..

    Quote Originally Posted by abcisme View Post
    Here's what my header says:

    PHP Code:
    /*
    //////////////////////////////////////////////////////////////////////////
    //  SUPER ORDERS v3.0                                                   //
    //                                                                      //
    //  Based on Super Order 2.0                                            //
    //  By Frank Koehl - PM: BlindSide (original author)                    //
    //                                                                      //
    //  Super Orders Updated by:                                            //
    //  ~ JT of GTICustom                                                    //
    //  ~ C Jones Over the Hill Web Consulting (http://overthehillweb.com)    //
    //  ~ Loose Chicken Software Development, [email protected]        //
    //                                                                      //
    //  Powered by Zen-Cart (www.zen-cart.com)                              //
    //  Portions Copyright (c) 2005 The Zen-Cart Team                       //
    //                                                                         //
    //  Released under the GNU General Public License                       //
    //  available at www.zen-cart.com/license/2_0.txt                       //
    //  or see "license.txt" in the downloaded zip                          //
    //////////////////////////////////////////////////////////////////////////
    //  DESCRIPTION:   PDF version of super_packingslip.php,                //
    //  Features include:                                                    //
    //    ~    Pricing information which supports tax included pricing options    //
    //        identical to super_invoices.php                                    //
    //  ~    Admin configurable options to use with forms that have a peel    //
    //        off    mailing label in place of the default "Packing Slip" text    //
    //////////////////////////////////////////////////////////////////////////
    // $Id: super_batch_forms.php v 2010-10-24 $ 
    My Site - Zen Cart & WordPress integration specialist
    I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.

  7. #927
    Join Date
    Jun 2006
    Posts
    298
    Plugin Contributions
    0

    Default Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

    Quote Originally Posted by DivaVocals View Post
    Awesome!!! Thanks for sharing..
    You're welcome. Like I said, I'm sure someone will come up with a better way of doing it, but that's what I could come up with for now. :)

  8. #928
    Join Date
    Jun 2006
    Posts
    298
    Plugin Contributions
    0

    Default Re: Super Orders v3.0 Support Thread (for ZC v1.3.9)

    Found one more hard coded text in the file. The "packing slip" title.

    Define TITLE_PACK_SLIP in admin/includes/languages/YOUR_LANGUAGE/super_batch_forms.php

    Code:
    define('TITLE_PACK_SLIP','Packing Slip');
    in admin/includes/functions/extra_functions/lcsd_merged_packing_slips.php

    Around line 73:

    Code:
    	if(LCSD_SHOW_SHIPPING_LABEL == 'False'){ 
    					$this->SetFont('Arial','B', 28);
    					$this->SetXY(350, 85);  
    					$this->MultiCell(270, 24, TITLE_PACK_SLIP); 
                }

  9. #929
    Join Date
    Nov 2012
    Posts
    100
    Plugin Contributions
    0

    Default Re: Super Orders v3.0 Support Thread

    I may be not seeing something but when I download all I get is a .php page without any accompanying files, i.e., the extensive readme noted.

    I am not seeing any current comments, either, although it seems that the module is being currently supported.

  10. #930

    Default Re: Super Orders v3.0 Support Thread

    Did you unzip the download package? If yes, and a single .php file is all that's there, then something went wrong with your download. Try again.

    Quote Originally Posted by WWWD View Post
    I may be not seeing something but when I download all I get is a .php page without any accompanying files, i.e., the extensive readme noted.

    I am not seeing any current comments, either, although it seems that the module is being currently supported.
    Go that extra mile, you never know what's at the end of the road

    Empowerment Sanctuary

 

 
Page 93 of 102 FirstFirst ... 43839192939495 ... LastLast

Similar Threads

  1. v150 Edit Orders v4.0 Support Thread
    By DivaVocals in forum Addon Admin Tools
    Replies: 1877
    Last Post: 6 May 2025, 05:10 PM
  2. v150 Super Orders v4.0 Support Thread for ZC v1.5.x
    By DivaVocals in forum Addon Admin Tools
    Replies: 804
    Last Post: 18 Apr 2025, 12:04 AM
  3. Edit Orders v3.0 for ZC 1.3.9 [Support Thread]
    By DivaVocals in forum All Other Contributions/Addons
    Replies: 656
    Last Post: 18 Apr 2016, 06:28 PM
  4. OLD Super Orders 2.0 (See v3.0 thread instead)
    By BlindSide in forum All Other Contributions/Addons
    Replies: 2019
    Last Post: 17 Jan 2012, 05:43 AM
  5. RE: Super Orders v3.0 Support Thread
    By Johnnyd in forum All Other Contributions/Addons
    Replies: 0
    Last Post: 22 Jun 2011, 09:28 AM

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
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR