Easy Digital Downloads
  • Package
  • Function
  • Tree

Packages

  • EDD
    • Admin
      • Actions
      • Add-ons
      • Dashboard
      • Discounts
      • Downloads
      • Export
      • Notices
      • Pages
      • Payments
      • Reports
      • Settings
      • System
      • Upgrades
      • Upload
      • Welcome
    • Cart
    • Checkout
    • Classes
      • API
      • Fees
      • HTML
      • Roles
      • Session
    • Emails
    • Functions
      • AJAX
      • Compatibility
      • Errors
      • Formatting
      • Install
      • Login
      • Taxes
      • Templates
    • Gateways
    • Logging
    • Payments
    • Shortcodes
    • Widgets

Functions

  • edd_export_all_customers
  • edd_export_all_downloads_history
  • edd_export_payment_history
 1 <?php
 2 /**
 3  * Exports Functions
 4  *
 5  * These are functions are used for exporting data from Easy Digital Downloads.
 6  *
 7  * @package     EDD
 8  * @subpackage  Admin/Export
 9  * @copyright   Copyright (c) 2013, Pippin Williamson
10  * @license     http://opensource.org/licenses/gpl-2.0.php GNU Public License
11  */
12 
13 // Exit if accessed directly
14 if ( ! defined( 'ABSPATH' ) ) exit;
15 
16 require_once EDD_PLUGIN_DIR . 'includes/admin/reporting/class-export.php';
17 
18 /**
19  * Exports all the payments stored in Payment History to a CSV file using the
20  * EDD_Export class.
21  *
22  * @since 1.4.4
23  * @return void
24  */
25 function edd_export_payment_history() {
26     require_once EDD_PLUGIN_DIR . 'includes/admin/reporting/class-export-payments.php';
27 
28     $payments_export = new EDD_Payments_Export();
29 
30     $payments_export->export();
31 }
32 add_action( 'edd_payment_export', 'edd_export_payment_history' );
33 
34 /**
35  * Export all the customers to a CSV file.
36  *
37  * Note: The WordPress Database API is being used directly for performance
38  * reasons (workaround of calling all posts and fetch data respectively)
39  *
40  * @since 1.4.4
41  * @return void
42  */
43 function edd_export_all_customers() {
44     require_once EDD_PLUGIN_DIR . 'includes/admin/reporting/class-export-customers.php';
45 
46     $customer_export = new EDD_Customers_Export();
47 
48     $customer_export->export();
49 }
50 add_action( 'edd_email_export', 'edd_export_all_customers' );
51 
52 /**
53  * Exports all the downloads to a CSV file using the EDD_Export class.
54  *
55  * @since 1.4.4
56  * @return void
57  */
58 function edd_export_all_downloads_history() {
59     require_once EDD_PLUGIN_DIR . 'includes/admin/reporting/class-export-download-history.php';
60 
61     $file_download_export = new EDD_Download_History_Export();
62 
63     $file_download_export->export();
64 }
65 add_action( 'edd_downloads_history_export', 'edd_export_all_downloads_history' );
Easy Digital Downloads API documentation generated by ApiGen 2.8.0