Page 88 of 100 FirstFirst ... 3878868788899098 ... LastLast
Results 871 to 880 of 998
  1. #871
    Join Date
    Sep 2018
    Location
    UUSA
    Posts
    40
    Plugin Contributions
    0

    Default Re: Track Package from FedEx, UPS, Postal, DHL, etc..

    Quote Originally Posted by jeking View Post
    Ok, revert to the old file and I'll take a look as soon as I can.
    Thank you..

  2. #872
    Join Date
    Oct 2005
    Location
    Chicago, IL USA
    Posts
    1,582
    Plugin Contributions
    29

    Default Re: Track Package from FedEx, UPS, Postal, DHL, etc..

    Change line 19 to be:
    Code:
      if (@sizeof($customer_orders)==0) {
    This was tested so should solve the issue.

  3. #873
    Join Date
    Sep 2018
    Location
    UUSA
    Posts
    40
    Plugin Contributions
    0

    Default Re: Track Package from FedEx, UPS, Postal, DHL, etc..

    thank you so much!! its work.

  4. #874
    Join Date
    Mar 2009
    Posts
    609
    Plugin Contributions
    0

    Default Re: Track Package from FedEx, UPS, Postal, DHL, etc..

    I need the tracking input fields shown in orders.php to remove spaces from the input before putting them into the db, on an older version of ty track I had this code in orders.php that would do the job.

    Code:
    // BEGIN TY TRACKER 1 - DEFINE VALUES ----------------------------------------------
            $track_id1 = str_replace(" ", "", zen_db_prepare_input($_POST['track_id1']));
            $track_id2 = str_replace(" ", "", zen_db_prepare_input($_POST['track_id2']));
            $track_id3 = str_replace(" ", "", zen_db_prepare_input($_POST['track_id3']));
            $track_id4 = str_replace(" ", "", zen_db_prepare_input($_POST['track_id4']));
            $track_id5 = str_replace(" ", "", zen_db_prepare_input($_POST['track_id5']));
            $track_id6 = str_replace(" ", "", zen_db_prepare_input($_POST['track_id6']));
            $track_id7 = str_replace(" ", "", zen_db_prepare_input($_POST['track_id7']));
    // END TY TRACKER 1 - DEFINE VALUES ------------------------------------------------------------------
    I can't find or figure out a place to put a str_replace to do the job on the latest version.

    I've found the similar code in edit_orders that uses an array and I've modified that to do what I need, but the orders.php code is different, any help greatly received.

  5. #875
    Join Date
    Mar 2009
    Posts
    609
    Plugin Contributions
    0

    Default Re: Track Package from FedEx, UPS, Postal, DHL, etc..

    Quote Originally Posted by DigitalShadow View Post
    I need the tracking input fields to remove spaces from the input before putting them into the db.
    Edit includes/functions/functions_osh_update.php

    find
    Code:
                // Begin Ty Package Tracker       
                foreach($track_id as $id => $track) {
                    $osh_sql['track_id' . $id] = zen_db_input($track);
                }
    replace with
    Code:
                // Begin Ty Package Tracker       
                foreach($track_id as $id => $track) {
                    $osh_sql['track_id' . $id] = str_replace(" ", "", zen_db_input($track));
                }

  6. #876
    Join Date
    Jun 2012
    Location
    California
    Posts
    238
    Plugin Contributions
    0

    Default Re: Track Package from FedEx, UPS, Postal, DHL, etc..

    I loaded this plug in in 1.5.7 and it appears the only error I keep getting is:

    PHP Warning: Invalid argument supplied for foreach() in /****/****/public_html/****/includes/functions/functions_osh_update.php on line 206.

    Can you supply a fix for this issue?

    Thank You

  7. #877
    Join Date
    Jun 2012
    Location
    California
    Posts
    238
    Plugin Contributions
    0

    Default Re: Track Package from FedEx, UPS, Postal, DHL, etc..

    1.5.7a
    PHP 7.4
    Name:  PlugIn List.png
Views: 103
Size:  3.3 KB

    I have Package tracker running in 1.5.7a but I am getting a PHP error stating:

    PHP Warning: Invalid argument supplied for foreach() in /home2/***/public_html/ZC157/includes/functions/functions_osh_update.php on line 206.

    While there were a few other issues that were easy to resolve in functions_osh_update it appears to be this portion of code below causing the issue:

    Code:
                // Begin Ty Package Tracker       
                foreach($track_id as $id => $track) {
                    $osh_sql['track_id' . $id] = zen_db_input($track);
                }
    Will the edit to trackid below resolve this error:

    Code:
                // Begin Ty Package Tracker       
                foreach('track_id' as $id => $track) {
                    $osh_sql['track_id' . $id] = str_replace(" ", "", zen_db_input($track));
                }
    Thank You for any assistance it is greatly appreciated

  8. #878
    Join Date
    Nov 2005
    Location
    los angeles
    Posts
    2,843
    Plugin Contributions
    11

    Default Re: Track Package from FedEx, UPS, Postal, DHL, etc..

    Quote Originally Posted by wsworx View Post
    Will the edit to trackid below resolve this error:

    Code:
                // Begin Ty Package Tracker       
                foreach('track_id' as $id => $track) {
                    $osh_sql['track_id' . $id] = str_replace(" ", "", zen_db_input($track));
                }
    NO!

    try:
    PHP Code:
               // Begin Ty Package Tracker       
               
    if (is_array($track_id) {
                foreach(
    $track_id as $id => $track) {
                    
    $osh_sql['track_id' $id] = zen_db_input($track);
                }
               } 
    you can still do that str_replace if so inclined...

    best.
    author of square Webpay.
    mxWorks now has Apple Pay and Google Pay. donations: venmo or paypal accepted.
    premium consistent excellent support. available for hire.

  9. #879
    Join Date
    Jun 2012
    Location
    California
    Posts
    238
    Plugin Contributions
    0

    Default Re: Track Package from FedEx, UPS, Postal, DHL, etc..

    Quote Originally Posted by carlwhat View Post
    NO!

    try:
    PHP Code:
               // Begin Ty Package Tracker       
               
    if (is_array($track_id) {
                foreach(
    $track_id as $id => $track) {
                    
    $osh_sql['track_id' $id] = zen_db_input($track);
                }
               } 
    you can still do that str_replace if so inclined...

    best.
    That edit broke the entire web site and caused the below error:

    [code]
    [04-Nov-2020 19:41:01 UTC] PHP Parse error: syntax error, unexpected 'foreach' (T_FOREACH) in /home2/***/public_html/ZC157/includes/functions/functions_osh_update.php on line 207

    [04-Nov-2020 19:41:01 UTC] Request URI: /ZC157/***/index.php?cmd=login, IP address: ***
    --> PHP Parse error: syntax error, unexpected 'foreach' (T_FOREACH) in /home2/***/public_html/ZC157/includes/functions/functions_osh_update.php on line 207.

  10. #880
    Join Date
    Sep 2009
    Location
    Stuart, FL
    Posts
    13,355
    Plugin Contributions
    94

    Default Re: Track Package from FedEx, UPS, Postal, DHL, etc..

    Missing a right-paren:
    Code:
               // Begin Ty Package Tracker       
               if (is_array($track_id)) {
                foreach($track_id as $id => $track) {
                    $osh_sql['track_id' . $id] = zen_db_input($track);
                }
               }

 

 
Page 88 of 100 FirstFirst ... 3878868788899098 ... LastLast

Similar Threads

  1. v150 Is there a FedEx plugin to quote on package size and postal code/zone?
    By Music Man in forum Addon Shipping Modules
    Replies: 7
    Last Post: 3 Aug 2014, 10:30 PM
  2. UPS/DHL shipping in Europe
    By DML73 in forum Built-in Shipping and Payment Modules
    Replies: 0
    Last Post: 29 Jan 2009, 09:43 PM
  3. what is the track your package url?
    By keylesslocks in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 29 Aug 2008, 06:49 PM
  4. going from small package to large package
    By luna_99 in forum Built-in Shipping and Payment Modules
    Replies: 0
    Last Post: 19 Nov 2007, 02:44 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