Results 1 to 5 of 5
  1. #1
    Join Date
    Mar 2005
    Location
    United Kingdom
    Posts
    574
    Plugin Contributions
    0

    Default Order Status Update / Append Comments & Noitify Customer

    Hi,

    I'm running a script that connects to my database and updates the order status and appends a tracking link but I can't figure out how to get this same script to fire off the email that would be sent if you did this manually via Orders >> Edit in Admin.

    The bit of script in question is as follows:

    PHP Code:
    {

    $string "My update text here";

    $connection mysql_connect($host,$usr,$pwd);
    $insert mysql_db_query($db"INSERT into zen_orders_status_history (orders_id, orders_status_id, date_added, comments) values ('$itemid', '9', '$now', '$string')"$connection);
    $update mysql_db_query($db"UPDATE zen_orders set orders_status='9' where orders_id='$itemid' "$connection);
    mysql_close($connection);


    I trawled through many previous posts but without luck. Assume the code I need is buried somewhere in orders.php but I'm paint by numbers when it comes to code so any pointers would be greatly appreciated.

    Regards,

    Brent

  2. #2
    Join Date
    Jan 2004
    Posts
    65,248
    Blog Entries
    7
    Plugin Contributions
    224

    Default Re: Order Status Update / Append Comments & Noitify Customer

    In v1.5.1, lines 105-234 of /admin/orders.php are what handle processing the inputs submitted on the browser and taking corresponding action to apply the updates and send the emails.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  3. #3
    Join Date
    Mar 2005
    Location
    United Kingdom
    Posts
    574
    Plugin Contributions
    0

    Default Re: Order Status Update / Append Comments & Noitify Customer

    Thank you DrByte!

  4. #4
    Join Date
    Jun 2007
    Posts
    418
    Plugin Contributions
    0

    Default Re: Order Status Update / Append Comments & Noitify Customer

    Brent,
    Any chance you can share more info on this script/tool you have created? It sounds like something I'd be interested in implementing.

  5. #5
    Join Date
    Jan 2007
    Location
    Los Angeles, California, United States
    Posts
    10,030
    Plugin Contributions
    32

    Default Re: Order Status Update / Append Comments & Noitify Customer

    Quote Originally Posted by Brent View Post
    Hi,

    I'm running a script that connects to my database and updates the order status and appends a tracking link but I can't figure out how to get this same script to fire off the email that would be sent if you did this manually via Orders >> Edit in Admin.
    Not sure if this is what you are trying to do with your script, but have you looked at the Ty Package Tracker add-on.. It allows you to send out a shipper tracking link to your customers..
    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.

 

 

Similar Threads

  1. v154 Order Comments Status/Update Boilerplate
    By lloyd_borrett in forum Managing Customers and Orders
    Replies: 40
    Last Post: 20 May 2019, 09:07 AM
  2. Order Status History & Comments
    By dmagic in forum Basic Configuration
    Replies: 3
    Last Post: 21 May 2015, 01:06 PM
  3. Order Status History & Comments
    By dmagic in forum Customization from the Admin
    Replies: 1
    Last Post: 21 May 2015, 10:06 AM
  4. v138a Append "Order Status" to the end of the Order Update Email Subject Line
    By kamokid in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 5 Jun 2013, 10:18 AM
  5. Status History & Comments (Customer & Admin side) Duplicate entries?
    By MaximumOverload in forum General Questions
    Replies: 3
    Last Post: 4 Apr 2011, 05:55 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
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR