Skip to content

Instantly share code, notes, and snippets.

View joshuaswilcox's full-sized avatar

Joshua Wilcox joshuaswilcox

View GitHub Profile
@joshuaswilcox
joshuaswilcox / xml_rpc_in_wordpress
Created October 8, 2012 19:50
XML RPC in Wordpress
Joshs-Mac-Pro:PEAR josh$ wget https://github.com/pear/XML_RPC2/zipball/trunk
--2012-10-08 15:45:22-- https://github.com/pear/XML_RPC2/zipball/trunk
Resolving github.com... 207.97.227.239
Connecting to github.com|207.97.227.239|:443... connected.
HTTP request sent, awaiting response... 302 Found
Location: https://nodeload.github.com/pear/XML_RPC2/zipball/trunk [following]
--2012-10-08 15:45:23-- https://nodeload.github.com/pear/XML_RPC2/zipball/trunk
Resolving nodeload.github.com... 207.97.227.252
Connecting to nodeload.github.com|207.97.227.252|:443... connected.
HTTP request sent, awaiting response... 200 OK
function _get_gate_form_title($nid, $vid) {
$row = _get_gate_row($nid, $vid);
$title = $row->form_title;
return $title;
}
function _get_gate_row ($nid, $vid) {
$result = db_query("SELECT * FROM gated_content WHERE nid = %d AND vid = %d", $nid, $vid);
$row = db_fetch_object($result);
@joshuaswilcox
joshuaswilcox / gist:3715949
Created September 13, 2012 17:20
Everything you can override in a refinerycms project with refinerycms-blog
When starting a project that includes refinerycms-blog:
$ rake refinery:override view=refinery/pages/*
$ rake refinery:override view=layouts/*
$ rake refinery:override view=refinery/blog/shared/*
$ rake refinery:override view=refinery/blog/posts/*
$ rake refinery:override view=refinery/*
$ rake refinery:override controller=refinery/blog/*
$ rake refinery:override controller=refinery/*