Pagely staging site

How to create a Pagely staging site (for the non-developer)

Chances are that you’ve heard of Pagely, as they were the first company to offer managed WordPress hosting. They’re one of two hosts we recommend, and we migrated all of our own sites to Pagely early this year. One feature that many eCommerce sites need as part of their managed hosting services are staging sites, as these help you test updates and debug issues so you don’t have to deactivate plugins or try out new…

Read More

WordPress development tutorials

WordPress Get DB Table Column Names

To get the column names for a MySQL database table in WordPress, use the following: global $wpdb; $table_name = $wpdb->prefix . ‘posts’; foreach ( $wpdb->get_col( “DESC ” . $table_name, 0 ) as $column_name ) { error_log( $column_name ); } Which will result in something like the following being printed to your debug.log: ID post_author post_date post_date_gmt post_content … You get the idea 🙂

Read More