function __construct()
 {
     $Options = apply_filters("WXP.get_options_object", new Options());
     $this->add_object("View", view_var("wxp_global_view"));
     $this->add_object("Options", new Observer("Options", $Options));
     $this->add_object("Path", WXP::get_template_paths());
 }
 function plugin_template_override()
 {
     /*
      * if the content template is included from a directory that
      * is not the theme directory, its more than likely that a plugin defined it
      * and we don't want our theme to override the plugin, so we'll set the
      * content_template back to the plugin's
      * 
      */
     $orig_tpl = WXP::DS(view_var("wxp_default_render_path"));
     $tpl_dir = WXP::DS(get_template_directory());
     $ss_dir = WXP::DS(get_stylesheet_directory());
     $override = view_var("wxp_allow_plugin_template_override");
     if (strpos($orig_tpl, $tpl_dir) === false && strpos($orig_tpl, $ss_dir) === false && $override === true) {
         $this->View->add("wxp_content_template", $orig_tpl);
         //let plugin template be single column, just incase
         //it includes its own sidebar (like Woocommerce)
         //$this->Elements->set_layout("one");
     }
 }
function wxp_reset_render_path()
{
    view_var("wxp_global_view")->set_render_path(view_var("wxp_default_render_path"));
}
 static function paginate()
 {
     view_var('transactions', paginate_find('Transaction', array('limit' => 10)));
 }
 static function password_expired()
 {
     parent::password_expired();
     view_var('user', globals('user'));
 }
<?php

\WXP\WXP::render_view(view_var("wxp_global_view"));
 /**
  * sets the following variables found in the #content_header view:
  * 
  * <b> $content_header_title </b> - a call to the the_title() function 
  * 
  * <b> $content_meta </b> - the name of the #content_meta template, inherits value of $post_format set in ::set_content method 
  * 
  * <b> $content_thumbnail </b> - the name of the #content_thumbnail template, inherits value of $post_format set in ::set_content method 
  * 
  */
 function set_content_header()
 {
     $the_title = new Action(function () {
         $before = "<h3>";
         $after = "</h3>";
         //if this is not a single post we wrap
         //the title in an anchor link to the single post
         if (!is_single()) {
             $link = get_the_permalink();
             $before .= "<a href='{$link}'>";
             $after = "</a>" . $after;
         }
         the_title($before, $after);
     });
     $post_format = view_var("post_format");
     $this->View->add("content_header_title", $the_title)->add("content_meta", $post_format)->add("content_thumbnail", $post_format);
 }