vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Member Archives (https://vborg.vbsupport.ru/forumdisplay.php?f=202)
-   -   Adding a new page (https://vborg.vbsupport.ru/showthread.php?t=44794)

diades 10-20-2002 06:44 PM

Adding a new page
 
Hi people

I found this:
Code:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML>
<HEAD><TITLE>$bbtitle - About</title>
$headinclude
</head>
<body>
$header
<p>Your code here!!!!!</p>
$footer
</body>
</html>

And make the new file about.php:
Code:

<?php
error_reporting(7);
require("./global.php");
eval("dooutput(\"".gettemplate('aboutmain')."\");");
?>

and used it to run a new page that I have created. The new page comes up ok but absolutely no content (I did change the template names accordingly).
Also, I would like to have it read the names of some other templates that are used within, can anyone shed some light please?

NTLDR 10-20-2002 06:57 PM

Quote:

Originally posted by diades
Also, I would like to have it read the names of some other templates that are used within, can anyone shed some light please?
Not sure I understand what your saying for this part ;)

And try c-prompts extra page driven by forum templates hack to do this if you haven't allready seen it :)

diades 10-20-2002 07:09 PM

Hi NTLDR

Thanks for the reply!

Regarding:
Quote:

Also, I would like to have it read the names of some other templates that are used within, can anyone shed some light please?
I have found that custom templates (bits not complete pages) have to be called also?

I have searched for the recommened therad in the hacks db but nothing came up (I also tried combinations etc., and have also searched on c-prompts in the members db in the hopes that, like yourself, there would be a libnk in the sig but both searches came up empty.

Erwin 10-20-2002 07:29 PM

diades - your code should work, as long as you name the custom template correctly - make sure the name is "aboutmain". Make sure "aboutmain" is in the all your templatesets especially your default templateset.

diades 10-20-2002 07:37 PM

Hi Erwin

"Make sure "aboutmain" is in the all your templatesets especially your default templateset."

I actually have this:
Code:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML>
<HEAD><TITLE>$bbtitle - About</title>
$headinclude
</head>
<body>
$header
$mainscript
$preloads

<p>Your code here!!!!!</p>
$footer
</body>
</html>

where the two lines in yellow are also custom templates(bits)
And links.php3:
Code:

<?php
error_reporting(7);
require("./global.php");
eval("dooutput(\"".gettemplate('links')."\");");
?>

It is called with:
"{forumlink}/links.php3?s=">
where links is the master page template.
I am only using it on one template at the moment to get it operational but, yes, I will naturally spread it accross when it is.

diades 10-21-2002 02:54 PM

Hi Guys

Would it help if I posted the script/markup that I am actually using?

Erwin 10-21-2002 10:34 PM

If $mainscript and $preloads are templates being called, you need to define these variables in the php file using dooutput.

diades 10-22-2002 10:24 PM

Hi

No luck so far!

We found c_prompts hack eventually and, after trying mine to no avail, I decided to use that hack verbatim the only difference being:
<p>Privacy Test</p> as content
all that I get is:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=windows-1252"></HEAD>
<BODY></BODY></HTML>

We are running 2.2.7 if that makes any difference

diades 10-25-2002 10:00 PM

We sorted thanks, used a different method


All times are GMT. The time now is 07:33 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.01068 seconds
  • Memory Usage 1,731KB
  • 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_code_printable
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (9)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