vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   misc.php rules hack (https://vborg.vbsupport.ru/showthread.php?t=59986)

bigdaddy04 01-10-2004 02:31 AM

misc.php rules hack
 
Hi everyone,
I was wondering, is there a hack for something like this:
http://hostingdiscussion.com/misc.php?s=&action=rules
Or where can I find instructions on how to achieve this?

Thanks in advance.

Zachery 01-10-2004 02:43 AM

Quote:

Originally Posted by bigdaddy04
Hi everyone,
I was wondering, is there a hack for something like this:
http://hostingdiscussion.com/misc.php?s=&action=rules
Or where can I find instructions on how to achieve this?

Thanks in advance.

that be a simple action change, however you could use in vB3 the faq manager to accompllish it. are you using vB2 or vB3?

bigdaddy04 01-10-2004 02:55 AM

vB2,
i know it should be simple, just a few lines added to misc.php and a new template, im just not sure of what to do exactly..

Zachery 01-10-2004 02:56 AM

Quote:

Originally Posted by bigdaddy04
vB2,
i know it should be simple, just a few lines added to misc.php and a new template, im just not sure of what to do exactly..

if you hold on a moment ill unzip 2.3.4 and make the nessary modifactions and share them :)

Zachery 01-10-2004 03:04 AM

first make a new template with your rules and whatever else youd like to have in there :)
make sure its called misc_rules

now

in misc.php find ?>

and add above

PHP Code:

// ####### Rules #######
if ($action=="rules") {
$templatesused "misc_rules";
include(
"./global.php");
eval(
"dooutput(\"".gettemplate("misc_rules")."\");");


i think that should be it lol ^^

bigdaddy04 01-10-2004 03:20 AM

Wow, Thanks a bunch!!!

Zachery 01-10-2004 05:07 AM

lemme know if theres any problems :)

bigdaddy04 01-10-2004 04:38 PM

Hi Faranth..

I got a question, say I want to add another page, not rules, just another page to misc.php..

What is the principal of doing that?

Zachery 01-10-2004 04:55 PM

Quote:

Originally Posted by bigdaddy04
Hi Faranth..

I got a question, say I want to add another page, not rules, just another page to misc.php..

What is the principal of doing that?

same steps find ?>

add above

PHP Code:

 // ####### Page #######
if ($action=="page") {
$templatesused "misc_page";
include(
"./global.php");
eval(
"dooutput(\"".gettemplate("misc_page")."\");");


change page to whatever you want, but make sure that templatesused and gettempalte are the same :)

Xenon 01-10-2004 04:58 PM

btw. it's vb3 style, but as it's nicer than vb2's style you should use this:

PHP Code:

eval('dooutput("' gettemplate('misc_page') . '");'); 

instead of
PHP Code:

eval("dooutput(\"".gettemplate("misc_page")."\");"); 



All times are GMT. The time now is 10:25 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.01069 seconds
  • Memory Usage 1,737KB
  • 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
  • (4)bbcode_php_printable
  • (3)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)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