Skip to content

Instantly share code, notes, and snippets.

View ptasker's full-sized avatar
:fishsticks:

Peter Tasker ptasker

:fishsticks:
View GitHub Profile
@ptasker
ptasker / gist:3369855
Created August 16, 2012 12:40 — forked from davidgtonge/gist:1227605
WPML Get homepage IDs
<?php
function get_wpml_home_ids(){
//Globalizse the $wpdb variable (instantiation of the wpdb class)
global $wpdb;
//Get the front-page id from the options table
$home_id = get_option('page_on_front');
//Run the query
@ptasker
ptasker / gist:3288142
Created August 7, 2012 18:36 — forked from luetkemj/wp-query-ref.php
WP: Query $args
<?php
/**
* WordPress Query Comprehensive Reference
* Compiled by luetkemj - luetkemj.com
*
* CODEX: http://codex.wordpress.org/Class_Reference/WP_Query
* Source: http://core.trac.wordpress.org/browser/tags/3.3.1/wp-includes/query.php
*/
$args = array(