How to export orders only with a defined status ?


I'm looking for a way to easily get exported orders in a CSV files but without having to slect each times orders in order search list results.

I would like to be able, from an url, to export records with the following needs


[]orders with a specific status I can input

]with a specific saved layout

[*]directly with an url that could be CRONed


The output file should be called directly from a browser or could be saved in specific folder on the server.

What I cannot do :

  • I cannot select each times orders from my order list as this job would be a waste of time : eac time to download the file, and to save it in folder of my computer… Too slow.

    ANy help or suggestion will help me,

    Thank you,



As no answer currently, I'll share my thoughts.

I think I could call for export only 'Processing' orders by calling an URL such as :§ion=orders&pattern_id=order_items&status="P"

But I need to know if it could work and what is the variable to soecify the right layout I want to use. (because I only want specific fields to be exported).

Thank you for help,



Hi there,

I'm surprised to see that no one is concerned by the export.

I don't know how people do to export their orders to shipping software. When we have over 30 or 40 parcels a day, we cannot do every morning manual export to download and then save the CSV in a specific folder to allow then our shipping software from our warrier to automatically get the shipping adresses.

I don't know how others do but I'm pretty sure that it could be exported simpky and automatically by just calling an URL or generating by cron a CSV file.

Up for help.



First off, you're posting in the wrong forum area. The “Labs” area is where cs-cart generally posts about new things that are in the works and where they are asking for help with beta testing, feedback, etc. I'm actually suprised they allow 'create' threads here.

You will need to do a bit of custom work related to the php hook 'get_orders'. You would check if $_REQUEST['status'] is set and if so, you'd add the condition to only return orders of that status. But you should probably only do this if CONTROLLER == 'exim' to avoid problems with other things that use this common (and extensively used) hook.

If you want this to be a cron job, exporting to a specific file on your server, then you'll have to set it up similar to the example below.

Suggest you move this thread to the developer section of the forum.


** Usage: Use the root of your store as the working directory for CRON
** Use this command line: php ./addons/my_changes/cron_iface.php --pw=
** where is the password used for password reminders in Administration/Settings/Security Settings
define('AREA', 'A');
define('AREA_NAME', 'admin');
if( !file_exists('./prepare.php') )

$cron_password = Registry::get('settings.Security.cron_password');
if( !$cron_password )
die('Bad pass');

if ((!isset($_REQUEST['pw']) || $cron_password != $_REQUEST['pw']) ) {

// Your code here



I would like to see a feature like this as well. I wish I had more experience building an add-on

for CS-Cart. Keep us posted on your progress though.