Skip to content

Instantly share code, notes, and snippets.

@JosephLenton
Created May 31, 2012 17:53
Show Gist options
  • Save JosephLenton/2845057 to your computer and use it in GitHub Desktop.
Save JosephLenton/2845057 to your computer and use it in GitHub Desktop.
wordpress header
<?php
/**
* Starts the PMC Proxy for redirecting to /app/view/blog
*
* @package PlayMyCode
* @subpackage PMC_Proxy
*/
define( 'ACCESS_OK', true );
include_once( $_SERVER["DOCUMENT_ROOT"] . '/flexi/flexi.php' );
$flexi = new Flexi();
$flexi->setWorkingDir( $_SERVER["DOCUMENT_ROOT"] . '/' )->
loadConfig( $_SERVER["DOCUMENT_ROOT"] . '/config.php' )->
loadConfig( $_SERVER["DOCUMENT_ROOT"] . '/config_local.php', true )->
loadConfig( $_SERVER["DOCUMENT_ROOT"] . '/frames.php' )->
setErrorReporting( false )->
preRun();
global $wpController;
$wpController = $flexi->newController( 'blog' );
$wpController->frame->view( 'head', 'blog/head' );
$wpController->load->view( 'blog/header' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment