Access WordPress Core Functions in a Plugin

Solution:

All WordPress functions are available in a plugin. The matter is hooking in the right place.

Simple example:

<?php
/**
 * Plugin Name: Test Plugin 
 */

// This hook is fired once WP, all plugins, and the theme are fully loaded and instantiated
add_action( 'wp_loaded', 'plugin_so_18538270' );

function plugin_so_18538270()
{
    // Admin area, do nothing
    if( is_admin() )
        return;

    // "true" == $var
    // See Yoda Conditions: http://www.codinghorror.com/blog/2012/07/new-programming-jargon.html
    if( isset( $_GET['print'] ) && "true" == $_GET['print'] ) 
    {
        // some code
        exit();
    }
}

References: