vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   How to copy the navbar? (https://vborg.vbsupport.ru/showthread.php?t=199566)

pjkcards 12-22-2008 11:30 PM

How to copy the navbar?
 
I want to copy my forum's navbar to another page off the site. How do I do this?

There is a lot of PHP embedded into it, which may make it hard. Is there an easy way to do this?

Thanks in advance.

RLShare 12-23-2008 01:11 AM

Is it a custom external page using Vbulletin templates? Either way, including global.php from the forum root will give you access to the $navbar variable which holds the navbar template code. But you should in all reality you should set the 'navbits' section and then rebuild it.

Dismounted 12-23-2008 02:23 AM

<a href="https://vborg.vbsupport.ru/showthread.php?t=62164" target="_blank">How to create your own vBulletin-powered page!</a>

pjkcards 12-23-2008 03:55 AM

No, it isn't an external page using vB templates. It is a wiki that is a sub-set of my site which uses vB. The wiki is in the /wiki directory, while vB is in the /forum directory. I want to include my navbar on the wiki, so I want to know how to copy it over.

Quote:

Either way, including global.php from the forum root will give you access to the $navbar variable which holds the navbar template code. But you should in all reality you should set the 'navbits' section and then rebuild it.
How do I go about that? Copy global.php into /wiki, and then copy the navbar code over? What do you mean set the 'navbits' section and rebuild? If you could give me more details, that would be greatly appreciated.

Thanks!

pjkcards 12-25-2008 02:45 AM

How do I go about that? Copy global.php into /wiki, and then copy the navbar code over? What do you mean set the 'navbits' section and rebuild? If you could give me more details, that would be greatly appreciated.

pjkcards 01-03-2009 11:13 PM

Any help with this would be great. I'd like to get this squared away ASAP so I can move onto the next project.

Thanks!

Lynne 01-04-2009 02:15 AM

in the php of the other pages, you would chdir to the vb directory and then include global.php:

PHP Code:

chdir ('/path/to/your/vbforums');
require_once(
'./global.php'); 


pjkcards 01-04-2009 02:59 AM

I don't quite understand. Do I simply copy all my navbar code, paste it into the /wiki page, and include the PHP code you pasted in it somewhere? Why chdir to the vb forums?

Lynne 01-04-2009 03:06 AM

No, I thought you wanted to include that actual template and if you do, you need to include global.php in your pages and I was telling you the code to include global.php in the pages.

I am unfamiliar with whatever wiki you are trying to install, so I can't really comment on whether that is the right way to go about it or if it's better to just copy the navbar html itself.

pjkcards 01-04-2009 03:21 AM

I have a Wiki installed as a sub-site of my forum. I want to create header so it looks very similar to the header of my forum, so users can navigate to the wiki without noticing too much of a difference. I have most of it complete, except I want the navbar displayed. It can be a custom navbar (HTML w/ links) that I will need to edit each time I add a link to the other navbar, but I simply want it to look the same. The navbar template has quite a bit of PHP (like if else statements) which would affect how the navbar looks. Hence, I am wondering if simply including the template would be easier. The navbar on my forum is actually built into the header, I can post the code if you can help me figure out what I need to do to make this work.

How would I go about this? Thanks!


All times are GMT. The time now is 01:35 AM.

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.01661 seconds
  • Memory Usage 1,736KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_php_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete