Ohh... Well ok, im pretty sure its an easy fix. is there a better section to post it.Oyabun1 wrote:phpBB template variables are not parsed in pages that are external to phpBB.
Is this any good for you?vaghar123@gmail.com wrote:Ohh... Well ok, im pretty sure its an easy fix. is there a better section to post it.Oyabun1 wrote:phpBB template variables are not parsed in pages that are external to phpBB.
Code: Select all
<?php
define('IN_PHPBB', true);
$phpbb_root_path = (defined('PHPBB_ROOT_PATH')) ? PHPBB_ROOT_PATH : './';
$phpEx = substr(strrchr(__FILE__, '.'), 1);
include($phpbb_root_path . 'common.' . $phpEx);
// Start session management
$user->session_begin();
$auth->acl($user->data);
$user->setup();
page_header('404 Error');
$template->set_filenames(array(
'body' => 404.html',
));
make_jumpbox(append_sid("{$phpbb_root_path}viewforum.$phpEx"));
page_footer();
?>
Code: Select all
<!-- INCLUDE overall_header.html -->
<h2>404 Error</h2>
<div class="panel">
<div class="inner"><span class="corners-top"><span></span></span>
<div class="content">
<p>
<img src="yourstyle/theme/images/404pic1.jpg">
</p>
</div>
<span class="corners-bottom"><span></span></span></div>
</div>
<!-- INCLUDE jumpbox.html -->
<!-- INCLUDE overall_footer.html -->
I just tried it, and it did not workStarskull wrote:I think your best bet would be to do it this way. This is the way I did it and achieved a great custom 404 error page. my 404 page for reference.
First create the php file. Name this file 404.php
Save this file to the root of your phpbb installation.Code: Select all
<?php define('IN_PHPBB', true); $phpbb_root_path = (defined('PHPBB_ROOT_PATH')) ? PHPBB_ROOT_PATH : './'; $phpEx = substr(strrchr(__FILE__, '.'), 1); include($phpbb_root_path . 'common.' . $phpEx); // Start session management $user->session_begin(); $auth->acl($user->data); $user->setup(); page_header('404 Error'); $template->set_filenames(array( 'body' => 404.html', )); make_jumpbox(append_sid("{$phpbb_root_path}viewforum.$phpEx")); page_footer(); ?>
Next you will make the actual html page.
Make a new page and name it 404.htmlSave and upload to yourstyle/template.Code: Select all
<!-- INCLUDE overall_header.html --> <h2>404 Error</h2> <div class="panel"> <div class="inner"><span class="corners-top"><span></span></span> <div class="content"> <p> <img src="yourstyle/theme/images/404pic1.jpg"> </p> </div> <span class="corners-bottom"><span></span></span></div> </div> <!-- INCLUDE jumpbox.html --> <!-- INCLUDE overall_footer.html -->
This should work. If the image code doesn't work use the direct path for it as in. http://yourdomain/styles/theme/images/404pic1.jpg
Hope this works for you.
<?php
and after the ?>
<img src="SE_Gamer/theme/images/404pic1.jpg">
<img src="{T_THEME_PATH}/images/404pic1.jpg">