PDA

View Full Version : Contributions that require header.php?



gamerigs
10-09-2005, 03:41 PM
I know oscMax doesn't have a catalog/includes/header.php file. I am trying to install a couple of contributions that need the header.php file


<!-- header //-->
<?php require(DIR_WS_INCLUDES . 'header.php'); ?>
<!-- header_eof //-->

How do you get around this? I've read a little bit about that templates/main_page_tpl.php being it substitute?

I need to know how to adjust the scripts so I don't get header.php syntax errors.

michael_s
10-10-2005, 08:06 AM
Just remove any header includes as it is not there. Then, any new code that the mod instructions tell you to put in header.php, put in main_page.tpl.php

Also, if the mods are adding new pages to the catalog, you must convert those pages to BTS format... There are a few posts about it here, do a search on adding new pages or BTS.

gamerigs
10-10-2005, 10:57 PM
Thanks for the helpful reply :D

So I would put


<!-- header //-->
<?php require('templates/fallback/main_page.tpl.php'); ?>
<!-- header_eof //-->

instead of header.php? Then modify any new pages the contribution 'adds' to BTS fomat.

michael_s
10-11-2005, 09:18 AM
No, you would remove any and all reference calls to header.php in any files of your mod.

I am assuming that the header code that you are referring to is in several new pages that your mod adds. BTS has no use for it, as all the header.php info is now lumped into main_page.tpl.php.

Then, you would need to convert that new page to BTS format. This includes removing the header.php and footer.php includes. See this thread:

http://oscdox.com/PNphpBB2-viewtopic-t-4842.html

It is for osCMax v1.7, but the process is the same...