Skip to content

Instantly share code, notes, and snippets.

View aolin480's full-sized avatar

Aaron Olin aolin480

View GitHub Profile
# This is a template .gitignore file for git-managed WordPress projects.
#
# Fact: you don't want WordPress core files, or your server-specific
# configuration files etc., in your project's repository. You just don't.
#
# Solution: stick this file up your repository root (which it assumes is
# also the WordPress root directory) and add exceptions for any plugins,
# themes, and other directories that should be under version control.
#
# See the comments below for more info on how to add exceptions for your
@aolin480
aolin480 / woocommerce-custom-cart-item-data.php
Created October 29, 2015 02:37 — forked from RadGH/woocommerce-custom-cart-item-data.php
Get and set custom cart item/product information prior to WooCommerce checkout, and carry those valus over to Order Item Metadata.
<?php
/*
Instructions:
1) Save data when adding to cart
When adding an item to your cart, use ld_woo_set_item_data. The best action for this to occur is
"woocommerce_add_to_cart". The first parameter for this action contains the "cart_item_key",
which is required for the function.
@aolin480
aolin480 / example-wp-list-table.php
Created March 8, 2017 20:41 — forked from paulund/example-wp-list-table.php
An example code of using the WP_List_Table class. With Pagination.
<?php
/*
* Plugin Name: Paulund WP List Table Example
* Description: An example of how to use the WP_List_Table class to display data in your WordPress Admin area
* Plugin URI: http://www.paulund.co.uk
* Author: Paul Underwood
* Author URI: http://www.paulund.co.uk
* Version: 1.0
* License: GPL2
*/