Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 General Discussions
Prev Previous Post   Next Post Next
  #1  
Old 08-28-2005, 08:20 AM
Vitesse Vitesse is offline
 
Join Date: Jun 2005
Location: Essex, UK
Posts: 41
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Navbar missing on custom page

Hi guys,

I've been writing a Quarter-Mile table for my forum. I know this has already been done but the existing one i found on here was aimed mainly at pro's by the looks of things i just wanted something really basic so i wrote my own.

Everything works except for some reason I dont have a forum nav bar at the top of the page (the php and template code looks identical to my 2nd page which has the navbar). I was wondering if someone could look over my code to see if they could see anywhere i've gone wrong as this is driving me totally nuts now.

Template
HTML Code:
$stylevar[htmldoctype]
<html dir="$stylevar[textdirection]" lang="$stylevar[languagecode]">
<head>
<title>$vboptions[bbtitle]</title>
$headinclude
</head>
<body>
$header

$navbar

<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
<tr>
	<td class="tcat"><div align="center">Performance Xtreme Quarter-mile times</div></td>
</tr>
<tr>
	<td class="alt1">Welcome to the new Quarter-Mile section of PerformanceXtreme, this is where you can see quarter-mile times for our members cars.<if condition="$bbuserinfo[username] =='Unregistered'"> Only registered members of PerformanceXtreme can add their car's time to the table, if you would like to add yours please login or register, registering only takes a few minutes and is totally free.</if></td>
</tr>
</table>
<br />
<br />
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="1" width="90%" align="center">
<td class="thead" align="center"> Username </td><td class="thead" align="center"> Car </td><td class="thead" align="center"> Reaction Time </td><td class="thead" align="center"> Quarter-Mile Time </td><td class="thead" align="center"> Terminal Speed </td>
$mydatabits
</table>
<br />
<br />
<if condition="$bbuserinfo[username] !='Unregistered'">
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="1" width="70%" align="center">
<tr>
<td class="tcat"><div align="center">Submit your time <if condition="is_member_of($bbuserinfo, 6)"> - Administrator functions</if>
</div></td>
</tr><tr><td>
<table>	
<form action="submittime.php" method="get">
<tr><td><div align="right">Reaction Time </div></td><td><input type="text" class="bginput" name="reactiontime" /></td><td> To 3 decimal places, Example: 1.123 </td></tr>
<tr><td><div align="right">Quarter Mile Time </div></td><td><input type="text" class="bginput" name="quarter" /></td><td> To 2 decimal places, Example 12.34 </td></tr>
<tr><td><div align="right">Terminal Speed (MPH) </div></td><td><input type="text" class="bginput" name="maxspeed" /></td><td> To 2 decimal places, Example 120.21</td></tr>
<if condition="is_member_of($bbuserinfo, 6)">
<tr><td><div align="right">Delete User from table  </div></td><td><input type="text" class="bginput" name="deluser" /></td></tr>
</if>
<tr><td></td><td>
<input type="submit" class="button" value="Submit" /></td></tr>
</form>
</table></td></tr>
<tr><td><strong>Please remember if your terminal speed is less than 100MPH you will need to add a leading zero <i> i.e. 090.12 </i></strong></td></tr></table></if>
<if condition="$bbuserinfo[username] =='Unregistered'">
<div align="center">If you want to submit your car in the Quarter Mile table then please either log-in or <strong><a href="http://www.performancextreme.com/forums/register.php">Register</a><strong></div>
</if>
$footer
</body>
</html>
PHP file
PHP Code:
<?php 

error_reporting
(E_ALL & ~E_NOTICE); 
define('NO_REGISTER_GLOBALS'1); 
define('THIS_SCRIPT''quartermile'); 
// get special phrase groups 
$phrasegroups = array( 

); 

$specialtemplates = array( 

); 


$globaltemplates = array( 
'Quartermile_table'
); 


$actiontemplates = array( 

); 

require_once(
'./global.php'); 


$mydatabits ''
$result $db->query_read("SELECT * FROM " TABLE_PREFIX "quartermile"); 
while (
$myrow =$db->fetch_array($result)) 

eval(
'$mydatabits .= "' fetch_template('mydatabit') . '";'); 

eval(
'print_output("' fetch_template('Quartermile') . '");');  


//Above the values read from the database

            
$navbits = array(); 
$navbits[$parent] = 'Submit Quarter Mile time'

$navbits construct_navbits($navbits); 
eval(
'$navbar = "' fetch_template('navbar') . '";'); 
eval(
'print_output("' fetch_template('Quartermile_table') . '");'); 


?>
If anyone can spot anything obviously wrong with this then i'd be greatly appreciative as it's the only thing holding me back from adding it to my site.

Like i mentioned before as far as i can tell the code is identical to that of the other page (navbar and template wise) and that page displays the navbar :ermm:

Thanks
Reply With Quote
 

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 11:12 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.03418 seconds
  • Memory Usage 2,367KB
  • Queries Executed 12 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)bbcode_html
  • (3)bbcode_php
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (3)post_thanks_box
  • (3)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (3)post_thanks_postbit_info
  • (3)postbit
  • (3)postbit_onlinestatus
  • (3)postbit_wrapper
  • (1)showthread_list
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_threadedmode.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids_threaded
  • showthread_threaded_construct_link
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete