vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   vBindex v2.1 (https://vborg.vbsupport.ru/showthread.php?t=41916)

NTLDR 08-24-2002 09:37 PM

You have two choices here, either add some PHP code to the phpinclude template (which will add extra queries to each page) or make a copy of vbindex.php and rename it and change the permissions at the top and the fefault template.

CarlosC 08-24-2002 09:43 PM

wich is the easier one?

CarlosC 08-24-2002 09:45 PM

both sound complicated for me.. :(

NTLDR 08-24-2002 09:50 PM

copy the vbindex.php to whatever name you want to call it, tetris.php for example and change home the following to the name of the template you created with the code for the tetris game:

PHP Code:

eval("dooutput(\"".gettemplate('home')."\");"); 

and change:

PHP Code:

// check is usergroup can view vBindex
$permissions=getpermissions();
if (!
$permissions[canviewvbindex]) {
  
show_nopermission();


To:

PHP Code:

// check if user is a guest
if ($bbuserinfo['usergroupid']==1) {
  
show_nopermission();



CarlosC 08-24-2002 10:00 PM

Quote:

eval("dooutput(\"".gettemplate('home')."\");");
Do you want me to change ('home') with ('tetris')?

NTLDR 08-24-2002 10:02 PM

Yes, that will make it display the teris template not the home one by default.

CarlosC 08-24-2002 10:04 PM

ok i did it and this is what i got:

http://www.tecnibyte.com/forum/tetris.php3

NTLDR 08-24-2002 10:06 PM

Have you got a template called tetris with the tetris HTML code in?

CarlosC 08-24-2002 10:08 PM

sorry i forgot to do that.. try again and see..

NTLDR 08-24-2002 10:12 PM

That works, but you need to make the other change at the top of the file so guests can't play ;)


All times are GMT. The time now is 09:11 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.02049 seconds
  • Memory Usage 1,738KB
  • 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
  • (3)bbcode_php_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (4)pagenav_pagelinkrel
  • (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