vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=15)
-   -   VB header on an external page.... (https://vborg.vbsupport.ru/showthread.php?t=87685)

imported_nightwalk8r 10-02-2003 06:56 AM

VB header on an external page....
 
i need help including the header and footer from my vb forums to a script that is outside the forums dir.
P.S. i've been trying to find the solution to it for hecka long time......search the board and everything.....so please help me out =(


Ex:

http://www.site.com/forums <<------Forums dir
http://www.site.com/page.php <<------Page to include the header and footer

Tony G 10-02-2003 10:43 AM

<a href="http://www.vbulletintemplates.com/mods/showthread.php?t=4564" target="_blank">http://www.vbulletintemplates.com/mo...ead.php?t=4564</a>

Then include $header and $footer in your template code and use the template to code the whole page.

imported_nightwalk8r 10-02-2003 12:32 PM

hmm.......i seems to keep on getting this error

Warning: main(./admin/config.php): failed to open stream: No such file or directory in /home/anim3df/public_html/global.php on line 129


My Code:

<?php
include("./global.php");
eval("dooutput(\"".gettemplate('header')."\");");
?>


Forums Dir:
http://www.site.com/forums

Test.php Dir
http://www.site.com/test.php

Tony G 10-02-2003 12:38 PM

That is wrong. You call a new template. Lets say it's called 'site' and put it into the file code. Then make a new template through your ACP called 'site'. So now the file name will call that template. Input the variable $header for the header to show, but use this with the stuff you'd like to display on the page.

imported_nightwalk8r 10-02-2003 12:44 PM

should i include the full path/or URL to the global.php?

include("./global.php"); <<--- in here

b/c if i put the site.php in the forums dir, it works......but i dont want it to be in the forums dir tho =/

Zachery 10-02-2003 01:11 PM

ok then try this


oh wait vb2 hmmm
lol hadda think for a moment, that should work
PHP Code:

<?php
 
// ## Changes the Directory so it will grab vb ##
chdir("/full/path/to/forum/");
// ## Grabs global.php so it will use vb2 functions ##
require("./global.php");
// ## Grabs a Sepecific Template ##
eval("dooutput(\"".gettemplate('templatename')."\");");
?>


imported_nightwalk8r 10-02-2003 04:23 PM

Quote:

Originally Posted by Faranth
ok then try this


oh wait vb2 hmmm
lol hadda think for a moment, that should work
PHP Code:

<?php
 
// ## Changes the Directory so it will grab vb ##
chdir("/full/path/to/forum/");
// ## Grabs global.php so it will use vb2 functions ##
require("./global.php");
// ## Grabs a Sepecific Template ##
eval("dooutput(\"".gettemplate('templatename')."\");");
?>




got another problem...u can see it here:

http://anim3.com/site.php

Zachery 10-02-2003 04:25 PM

go into the ACP and define the image paths like

http://yourforums.com/forumsdir/imgdir/

Tony G 10-03-2003 12:05 AM

Eep, didn't realise this was in the wrong forum. Moving to vB2 support..

Zachery 10-03-2003 03:57 AM

i already thought this was in vb2 lol :D


All times are GMT. The time now is 08:59 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.01181 seconds
  • Memory Usage 1,735KB
  • 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
  • (2)bbcode_php_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (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
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete