You're going about this in the wrong way. The template lynne gives you, gives you the ability to build vBulletin pages. The vbulletin way, you're coming at this kind of sideways, in a way we wouldn't normally do this
You really want something closer to this
Code:
<?php
define('THIS_SCRIPT', 'idiotadmin-pagex');
define('CSRF_PROTECTION', true);
// change this depending on your filename
// ################### PRE-CACHE TEMPLATES AND DATA ######################
// get special phrase groups
$phrasegroups = array();
// get special data templates from the datastore
$specialtemplates = array();
// pre-cache templates used by all actions
$globaltemplates = array(
'header',
'headinclude',
'navbar',
'mypage',
'footer'
);
// pre-cache templates used by specific actions
$actiontemplates = array();
// ######################### REQUIRE BACK-END ############################
// if your page is outside of your normal vb forums directory, you should change directories by uncommenting the next line
// chdir ('/path/to/your/forums');
include('./global.php');
// #######################################################################
// ######################## START MAIN SCRIPT ############################
// #######################################################################
$navbits = construct_navbits(array('' => 'navbar'));
$navbar = render_navbar_template($navbits);
// ###### YOUR CUSTOM CODE GOES HERE #####
$pagetitle = 'MyPage';
// ###### NOW YOUR TEMPLATE IS BEING RENDERED ######
$templater = vB_Template::create('mypage');
$templater->register_page_templates();
$templater->register('navbar', $navbar);
$templater->register('pagetitle', $pagetitle);
print_output($templater->render());
What this does is,
Defines what the page is (this_script)
Requires the needed phrases (we didn't do that here, since we're not using any)
Registers the templates that will be used on the page, these global templates at the top tell the software it needs these templates, so the software will get them all, instead of having to query for each template.
Requires the needed files.
Set's up the navbar
Set's up the page title
betwee the navbar stuff, and the page output stuff, you can do a lot of things. But if you just want a custom page, this is it
And then finally renders the templates.
Next, you'd add a new template in the software, based on my example it'd be mypage, AdminCP > Styles & Templates >STyle Manager > Add New Template
I've added the templates, and my custom html, stuff in it, and saved. Now it actually is a real page.
I did this pretty hastily, so I think I didn't get the navibts part right, but that is something I think with some trial and effort, and help from others, you should be able to nail down.