Importing a MAMP mysql database on mac (OS X Yosemite)

How to import a MAMP mysql database (bypassing phpmyadmin problems) Recently I’ve being have a problem importing a large database in MAMP Mysql via phpmyadmin (and after altering various php variables in php.ini, I still couldn’t get it to import). So I tried another approach to import it from the command line a quick google … Read more

Handy Woocommerce SQL queries

This post is just a place to store handy SQL queries for Woocommerce. Get Order and all its information select p.ID as order_id, p.post_date, pm.* from wp_posts p join wp_postmeta pm on p.ID = pm.post_id join wp_woocommerce_order_items oi on p.ID = oi.order_id where post_type = ‘shop_order’ and p.ID = 14223 Generate an Orders report and … Read more

How to make a WordPress Theme, Woocommerce Compatible from scratch

beginners guide to theming Woocommerce

In this post I’ll going to explain how I took a WordPress Bootstrap Theme and made it Woocommerce Compatible. I couldn’t find many good tutorials on this so I’m writing this one, so that it might help someone else. The Process to make a theme Woocommerce Compatible I’m going to take the very nice DevDmBootstrap3 theme and make it Woocommerce … Read more

Woocommerce – Add an Important Admin Note to the Order Report for Order pickers to view

In this article I’ll show you how to add an Important Admin Note to the Order Report, very useful if there’s some information you want to add for Order pickers to view. For instance maybe the item is fragile you can highlight this to the order picker.   This plugin allows you to enter an Admin note on … Read more

Buddypress how to create a group programmatically in PHP (and add users)

In this post I’ll show you how to create a new group in PHP and then add users to the group. In this example I’m adding new users to a new group when they register. add_action(‘user_register’, ‘greenbox_add_user_to_new_buddypress_group’); //this should only fire on create user, therefore no problem with dupe groups function greenbox_add_user_to_new_buddypress_group($user_id) { $id_group = greenbox_create_bp_group($user_id); … Read more

WordPress create admin reports using WP_List_Table

Wordpress create admin reports using WP_List_Table

In this post I’m going to discuss how to use WP_List_Table to create reports/tables/lists that are similar in style to the standard WordPress reports for Posts, Pages etc. To achieve this I’ll use the WP_List_Table core WordPress class, this contains the functionality to create said tables/reports. This example will look at the links table and … Read more