Skip to content

Instantly share code, notes, and snippets.

@korrio
korrio / export.php
Created December 19, 2017 10:02
export script for importing to woocommerce via product im-ex plugin
<?php
//ini_set('display_errors', 1);
//ini_set('display_startup_errors', 1);
//error_reporting(E_ALL);
//aq1.co/wordpress/csv/export.php
require_once("_db.php");
$filename = 'export.xls'; // The file name you want any resulting file to be called
$db = new Database("wp_thg_import", "<YOUR-MYSQL-USERNAME>", "YOUR-MYSQL-PASSWORD", "localhost"); // $host is optional and defaults to 'localhost'