Page 2 of 2 FirstFirst 12
Results 11 to 20 of 38

Hybrid View

  1. #1
    Join Date
    Apr 2010
    Posts
    282
    Plugin Contributions
    1

    Default Stamps.com setting error while importing.

    I recently upgraded to the new stamps.com software, and you now install it in the admin folder, and it goes straight to the database. It is working flawlessly, except it sets an error in the log folder every time.

    I had to edit out the admin folder name, and login credentials on this:
    Code:
    [18-Sep-2015 10:07:27 America/Denver] Request URI: /XXXXXXXXXXXXXXXX/stamps.php?username=XXXXXXXXXXXXXXXX&password=XXXXXXXXXXXXXXXX&action=getorders&maxcount=50&start=2015-09-17T22%3A00%3A51, IP address: 216.52.211.20
    #1  mysql_real_escape_string() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:828]
    #2  GetCountryID() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:846]
    #3  GetStateCode() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:492]
    #4  WriteOrder() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:384]
    #5  Action_GetOrders() called at [/home2/redsauto/XXXXXXXXXXXXXXXX/stamps.php:176]
    
    [18-Sep-2015 10:07:27 America/Denver] PHP Warning:  mysql_real_escape_string(): Access denied for user 'XXXXXXXXXXXXXXXX'@'localhost' (using password: NO) in /home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php on line 828
    [18-Sep-2015 10:07:27 America/Denver] Request URI: XXXXXXXXXXXXXXXX/stamps.php?username=XXXXXXXXXXXXXXXX&password=XXXXXXXXXXXXXXXX&action=getorders&maxcount=50&start=2015-09-17T22%3A00%3A51, IP address: 216.52.211.20
    #1  mysql_real_escape_string() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:828]
    #2  GetCountryID() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:846]
    #3  GetStateCode() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:492]
    #4  WriteOrder() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:384]
    #5  Action_GetOrders() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:176]
    
    [18-Sep-2015 10:07:27 America/Denver] PHP Warning:  mysql_real_escape_string(): A link to the server could not be established in /home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php on line 828
    [18-Sep-2015 10:07:27 America/Denver] Request URI: /XXXXXXXXXXXXXXXX/stamps.php?username=XXXXXXXXXXXXXXXX&password=XXXXXXXXXXXXXXXX&action=getorders&maxcount=50&start=2015-09-17T22%3A00%3A51, IP address: 216.52.211.20
    #1  mysql_real_escape_string() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:855]
    #2  GetStateCode() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:492]
    #3  WriteOrder() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:384]
    #4  Action_GetOrders() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:176]
    
    [18-Sep-2015 10:07:27 America/Denver] PHP Warning:  mysql_real_escape_string(): Access denied for user 'XXXXXXXXXXXXXXXX'@'localhost' (using password: NO) in /home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php on line 855
    [18-Sep-2015 10:07:27 America/Denver] Request URI: /XXXXXXXXXXXXXXXX/stamps.php?username=XXXXXXXXXXXXXXXX&password=XXXXXXXXXXXXXXXX&action=getorders&maxcount=50&start=2015-09-17T22%3A00%3A51, IP address: 216.52.211.20
    #1  mysql_real_escape_string() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:855]
    #2  GetStateCode() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:492]
    #3  WriteOrder() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:384]
    #4  Action_GetOrders() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:176]
    
    [18-Sep-2015 10:07:27 America/Denver] PHP Warning:  mysql_real_escape_string(): A link to the server could not be established in /home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php on line 855
    [18-Sep-2015 10:07:27 America/Denver] Request URI: /XXXXXXXXXXXXXXXX/stamps.php?username=XXXXXXXXXXXXXXXX&password=XXXXXXXXXXXXXXXX&action=getorders&maxcount=50&start=2015-09-17T22%3A00%3A51, IP address: 216.52.211.20
    #1  mysql_real_escape_string() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:856]
    #2  GetStateCode() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:492]
    #3  WriteOrder() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:384]
    #4  Action_GetOrders() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:176]
    
    [18-Sep-2015 10:07:27 America/Denver] PHP Warning:  mysql_real_escape_string(): Access denied for user 'XXXXXXXXXXXXXXXX'@'localhost' (using password: NO) in /home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php on line 856
    [18-Sep-2015 10:07:27 America/Denver] Request URI: /XXXXXXXXXXXXXXXX/stamps.php?username=XXXXXXXXXXXXXXXX&password=XXXXXXXXXXXXXXXX&action=getorders&maxcount=50&start=2015-09-17T22%3A00%3A51, IP address: 216.52.211.20
    #1  mysql_real_escape_string() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:856]
    #2  GetStateCode() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:492]
    #3  WriteOrder() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:384]
    #4  Action_GetOrders() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:176]
    
    [18-Sep-2015 10:07:27 America/Denver] PHP Warning:  mysql_real_escape_string(): A link to the server could not be established in /home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php on line 856
    [18-Sep-2015 10:07:27 America/Denver] Request URI: /XXXXXXXXXXXXXXXX/stamps.php?username=XXXXXXXXXXXXXXXX&password=XXXXXXXXXXXXXXXX&action=getorders&maxcount=50&start=2015-09-17T22%3A00%3A51, IP address: 216.52.211.20
    #1  mysql_real_escape_string() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:828]
    #2  GetCountryID() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:846]
    #3  GetStateCode() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:506]
    #4  WriteOrder() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:384]
    #5  Action_GetOrders() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:176]
    
    [18-Sep-2015 10:07:27 America/Denver] PHP Warning:  mysql_real_escape_string(): Access denied for user 'XXXXXXXXXXXXXXXX'@'localhost' (using password: NO) in /home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php on line 828
    [18-Sep-2015 10:07:27 America/Denver] Request URI: /XXXXXXXXXXXXXXXX/stamps.php?username=XXXXXXXXXXXXXXXX&password=XXXXXXXXXXXXXXXX&action=getorders&maxcount=50&start=2015-09-17T22%3A00%3A51, IP address: 216.52.211.20
    #1  mysql_real_escape_string() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:828]
    #2  GetCountryID() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:846]
    #3  GetStateCode() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:506]
    #4  WriteOrder() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:384]
    #5  Action_GetOrders() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:176]
    
    [18-Sep-2015 10:07:27 America/Denver] PHP Warning:  mysql_real_escape_string(): A link to the server could not be established in /home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php on line 828
    [18-Sep-2015 10:07:27 America/Denver] Request URI: /XXXXXXXXXXXXXXXX/stamps.php?username=XXXXXXXXXXXXXXXX&password=XXXXXXXXXXXXXXXX&action=getorders&maxcount=50&start=2015-09-17T22%3A00%3A51, IP address: 216.52.211.20
    #1  mysql_real_escape_string() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:855]
    #2  GetStateCode() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:506]
    #3  WriteOrder() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:384]
    #4  Action_GetOrders() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:176]
    
    [18-Sep-2015 10:07:27 America/Denver] PHP Warning:  mysql_real_escape_string(): Access denied for user 'XXXXXXXXXXXXXXXX'@'localhost' (using password: NO) in /home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php on line 855
    [18-Sep-2015 10:07:27 America/Denver] Request URI: /XXXXXXXXXXXXXXXX/stamps.php?username=XXXXXXXXXXXXXXXX&password=XXXXXXXXXXXXXXXX&action=getorders&maxcount=50&start=2015-09-17T22%3A00%3A51, IP address: 216.52.211.20
    #1  mysql_real_escape_string() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:855]
    #2  GetStateCode() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:506]
    #3  WriteOrder() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:384]
    #4  Action_GetOrders() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:176]
    
    [18-Sep-2015 10:07:27 America/Denver] PHP Warning:  mysql_real_escape_string(): A link to the server could not be established in /home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php on line 855
    [18-Sep-2015 10:07:27 America/Denver] Request URI: /XXXXXXXXXXXXXXXX/stamps.php?username=XXXXXXXXXXXXXXXX&password=XXXXXXXXXXXXXXXX&action=getorders&maxcount=50&start=2015-09-17T22%3A00%3A51, IP address: 216.52.211.20
    #1  mysql_real_escape_string() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:856]
    #2  GetStateCode() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:506]
    #3  WriteOrder() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:384]
    #4  Action_GetOrders() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:176]
    
    [18-Sep-2015 10:07:27 America/Denver] PHP Warning:  mysql_real_escape_string(): Access denied for user 'XXXXXXXXXXXXXXXX'@'localhost' (using password: NO) in /home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php on line 856
    [18-Sep-2015 10:07:27 America/Denver] Request URI: /XXXXXXXXXXXXXXXX/stamps.php?username=XXXXXXXXXXXXXXXX&password=XXXXXXXXXXXXXXXX&action=getorders&maxcount=50&start=2015-09-17T22%3A00%3A51, IP address: 216.52.211.20
    #1  mysql_real_escape_string() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:856]
    #2  GetStateCode() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:506]
    #3  WriteOrder() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:384]
    #4  Action_GetOrders() called at [/home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php:176]
    
    [18-Sep-2015 10:07:27 America/Denver] PHP Warning:  mysql_real_escape_string(): A link to the server could not be established in /home2/redsauto/public_html/XXXXXXXXXXXXXXXX/stamps.php on line 856
    Lines 171-179
    Code:
                                   switch (strtolower($action))
                                    {
                                            case 'getmodule': Action_GetModule(); break;
                                            case 'getstore': Action_GetStore(); break;
                                            case 'getcount': Action_GetCount(); break;
                                            case 'getorders': Action_GetOrders(); break;
                                            case 'getstatuscodes': Action_GetStatusCodes(); break;
                                            case 'updatestatus': Action_UpdateStatus(); break;
                                            default: outputError(60, "'$action' not supported");
    lines 381-387
    Code:
                            $processedIds .= $row->fields['orders_id'];
    
                            // output the order xml
                            WriteOrder($row);
    
                            // Next order
                            $row->MoveNext();
    lines 485-497
    Code:
                    writeStartTag("ShippingAddress");
                    writeElement("FullName", $row->fields['delivery_name']);
                    writeElement("Company", $row->fields['delivery_company']);
                    writeElement("Street1", $row->fields['delivery_street_address']);
                    writeElement("Street2", $row->fields['delivery_suburb']);
                    writeElement("Street3", "");
                    writeElement("City", $row->fields['delivery_city']);
                    writeElement("State", GetStateCode($row->fields['delivery_country'], $row->fields['delivery_state']));
                    writeElement("PostalCode", $row->fields['delivery_postcode']);
                    writeElement("Country", $row->fields['delivery_country']);
                    writeElement("Phone", $shipPhone);
                    writeElement("Email", $shipEmail);
                    writeCloseTag("ShippingAddress");
    lines 824-867
    Code:
            function GetCountryID($country_name)
            {
                    global $db;
                    $qry = sprintf("select countries_id from ". TABLE_COUNTRIES. " where countries_name = '%s'",
                                    mysql_real_escape_string($country_name));
    
                    $countryQuery = $db->Execute($qry);
                    if ($countryQuery->RecordCount() == 0)
                    {
                            return $country_name;
                    }
                    else
                    {
                            return $countryQuery->fields['countries_id'];
                    }
            }
    
            // Returns the state code for a given state and country name
            function GetStateCode($country_name, $state_name)
            {
                    global $db;
    
                    $country_id = GetCountryID($country_name);
    
                    if ($country_id == '')
                    {
                            return $state_name;
                    }
    
                    // now lookup the state code based on countryid and state name
                    $qry = sprintf("select zone_code from ". TABLE_ZONES. " where zone_country_id = '%s' and zone_name = '%s'",
                                    mysql_real_escape_string($country_id),
                                    mysql_real_escape_string($state_name));
                    $stateQuery = $db->Execute($qry);
                    if ($stateQuery->RecordCount() == 0)
                    {
                            return $state_name;
                    }
                    else
                    {
                            return $stateQuery->fields['zone_code'];
                    }
    
            }

  2. #2
    Join Date
    Sep 2009
    Location
    Stuart, FL
    Posts
    13,940
    Plugin Contributions
    96

    Default Re: Stamps.com setting error while importing.

    I've reported this issue to stamps.com (and included the suggested correction). There are 3 areas to be changed:
    Line 776:
    Code:
                    $comments = /*mysql_escape_string($_REQUEST['comments'])*/ $db->prepare_input ($_REQUEST['comments']);  //-20150917-lat9  *** 1 of 3 ***
    Line 828
    Code:
                                    /*mysql_real_escape_string($country_name)*/ $db->prepare_input ($country_name));  //-20150917-lat9  *** 2 of 3 ***
    Lines 854-856
    Code:
                    $qry = sprintf("select zone_code from ". TABLE_ZONES. " where zone_country_id = '%s' and zone_name = '%s'",
                                    /*mysql_real_escape_string($country_id)*/ $db->prepare_input ($country_id),
                                    /*mysql_real_escape_string($state_name)*/ $db->prepare_input ($state_name));  //-20150917-lat9  *** 3 of 3 ***

  3. #3
    Join Date
    Apr 2010
    Posts
    282
    Plugin Contributions
    1

    Default Re: Stamps.com setting error while importing.

    Thank you, that fixed it.

  4. #4
    Join Date
    Sep 2009
    Location
    Stuart, FL
    Posts
    13,940
    Plugin Contributions
    96

    Default Re: Stamps.com setting error while importing.

    Excellent! According to the customer-care email that I received from stamps.com, they should have those changes incorporated real-soon-now.

  5. #5
    Join Date
    Apr 2010
    Posts
    282
    Plugin Contributions
    1

    Default Re: Stamps.com setting error while importing.

    You mean, two years from now, right?

  6. #6
    Join Date
    Sep 2009
    Location
    Stuart, FL
    Posts
    13,940
    Plugin Contributions
    96

    Default Re: Stamps.com setting error while importing.

    Quote Originally Posted by vanhorn_s View Post
    You mean, two years from now, right?
    We'll see; they were quite responsive to the email query that I sent in. Since they've got the fix, "all" they need to do is re-validate and release!

  7. #7
    Join Date
    Aug 2011
    Posts
    9
    Plugin Contributions
    0

    Default Upgraded from 1.5.1-Stamps.com 'batch" orders now not importing-ideas?

    I recently upgraded my site from 1.5.1 to 1.5.5. The process involved building the new store on a new server. Everything seemed to be working perfectly, so went live and started accepting orders in the new store. When it came time to import the orders into my stamps.com software. (Using the latest software version on my machine here, not the web based stamps.com app) I keep getting the error of "no new orders".

    My database specs-
    PHP Version 7.0.27-0+deb9u1

    The error that is coming up in my log files-

    Code:
     [06-Apr-2018 08:43:10 America/New_York] PHP Fatal error:  Uncaught Error: Call to undefined function mysql_real_escape_string() in /usr/local/4admin/apache/vhosts/site.com/httpdocs/zen/admin/stamps.php:829
    Stack trace:
    #0 /usr/local/4admin/apache/vhosts/site.com/httpdocs/zen/admin/stamps.php(847): GetCountryID('United States')
    #1 /usr/local/4admin/apache/vhosts/site.com/httpdocs/zen/admin/stamps.php(493): GetStateCode('United States', 'Indiana')
    #2 /usr/local/4admin/apache/vhosts/site.com/httpdocs/zen/admin/stamps.php(385): WriteOrder(Object(queryFactoryResult))
    #3 /usr/local/4admin/apache/vhosts/site.com/httpdocs/zen/admin/stamps.php(176): Action_GetOrders()
    #4 {main}
      thrown in /usr/local/4admin/apache/vhosts/site.com/httpdocs/zen/admin/stamps.php on line 829
    I've been talking to stamps.com about the issue and at the moment its at their "level 2" support department and has been for about a week. I was hoping to see if anyone has had the same issue and might be able to offer some insight? Surely with the upgrades to 1.5.5/the new PHP version that uses "mysqli" statements someone has run into this?

    I'm leaning towards the zencart plugin for stamps.com needing to be updated? (I'm using the one that's available from stamps.com)

    But what's really strange is I have been manually printing the orders and updated my zencart admin to mark the orders as shipped. After doing a few orders, I tried importing them, and got about 15 to successfully import into stamps.com (yet not all of the orders that needed to be imported) However the post back by stamps.com to zencart to mark them as "shipped" and add the tracking number did not work.

    Thanks in advance for any help!

  8. #8
    Join Date
    Aug 2009
    Location
    North Idaho, USA
    Posts
    2,008
    Plugin Contributions
    1

    Default Re: Upgraded from 1.5.1-Stamps.com 'batch" orders now not importing-ideas?

    Free or paid stamps.com account? If paid, you might consider shipstation which is owned by stamps.com no plugin to keep updated, since it is browser based interface and postage should transfer since it is purchased using stamps.com login.

    The last time stamps.com referredmy issue to tier 2, received an answer 9.5 months later. 9 months after swiching to shipst########
    Rick
    RixStix (dot) com
    aka: ChainWeavers (dot) com

  9. #9
    Join Date
    Aug 2011
    Posts
    9
    Plugin Contributions
    0

    Default Re: Upgraded from 1.5.1-Stamps.com 'batch" orders now not importing-ideas?

    Thanks so much for the input, yikes on how long it took tier 2 to get back to you!

    I have a paid stamps.com account, didn't know there were free ones. I've looked shipstation, it might be an option. Stamps.com has been working out really well for me, so I'd like to stick to it if possible.

  10. #10
    Join Date
    Nov 2007
    Location
    Woodbine, Georgia, United States
    Posts
    4,247
    Plugin Contributions
    58

    Default Re: Upgraded from 1.5.1-Stamps.com 'batch" orders now not importing-ideas?

    Actually that's not it.... Here are the changes

    Around line 829 find
    Code:
    mysql_real_escape_string($country_name));
    change to
    Code:
    zen_db_input($country_name));
    Then around line 856 find
    Code:
    mysql_real_escape_string($country_id),
    mysql_real_escape_string($state_name));
    Change to
    Code:
    zen_db_input($country_id),
    zen_db_input($state_name));
    ~Melanie
    PRO-Webs, Inc. since 2003 :: Zen Cart Hosting :: Zen Cart SEO – 12 Steps to Success
    **I answer questions in the forum, private messages are not conducive to a helpful community.

 

 
Page 2 of 2 FirstFirst 12

Similar Threads

  1. v138a Stamps.com: How do I prevent Non-shippable items from batch importing?
    By gachogavacho in forum Addon Shipping Modules
    Replies: 14
    Last Post: 20 Aug 2014, 08:07 AM

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