https://www.icyphoenix.com/viewtopic.php?f=35&t=5289&p=35682#p35682
-----------------------------------
redrumm101
Fri 16 Jan, 2009 20:51

Re: Adding A Simple Php Page
-----------------------------------
Ok i was able to get this to work somewhat with my server info page

http://www.getcis.com/~redrum/server.php#22

But of course i doesnt look right.. I used the rules page to copy most of the code and put my code inbetween.. Its just a standard echo iframe. Any help would be greatly appreciated.. Here is the code i used like i said most of it is rules.php because thats the only way i can seem to get it to work. 

If there is a much simpler way to do this and have the correct borders around it and top and bottom title bar.

[code linenumbers=false]<?php
/***************************************************************************
 *                              rules.php
 *                            -------------------
 *   begin                : 26.10.2003, 19:29
 *   copyright            : (C) 2003 Dimitri Seitz
 *   email                : dwing@weingarten-net.de
 *
 *   $Id: admin_rules.php,v 2.0,
 *
 *
 ***************************************************************************/

define('IN_PHPBB', true);
$phpbb_root_path = './';
include($phpbb_root_path . 'extension.inc');
include($phpbb_root_path . 'common.' . $phpEx);
require "/home/redrum/bin/CON-Config.php";

// Start session management
$userdata = session_pagestart($user_ip);
init_userprefs($userdata);
// End session management

$cms_page_id = '22';
$cms_page_name = 'server info';
$auth_level_req = $board_config['auth_view_rules'];
if ($auth_level_req > AUTH_ALL)
{
	if ( ($auth_level_req == AUTH_REG) && (!$userdata['session_logged_in']) )
	{
		message_die(GENERAL_MESSAGE, $lang['Not_Auth_View']);
	}
	if ($userdata['user_level'] != ADMIN)
	{
		if ( $auth_level_req == AUTH_ADMIN )
		{
			message_die(GENERAL_MESSAGE, $lang['Not_Auth_View']);
		}
		if ( ($auth_level_req == AUTH_MOD) && ($userdata['user_level'] != MOD) )
		{
			message_die(GENERAL_MESSAGE, $lang['Not_Auth_View']);
		}
	}
}
$cms_wide_blocks = ($board_config['wide_blocks_rules'] == 1) ? true : false;

// Load the appropriate Rules file
$lang_file = 'lang_rules';
$l_title = $lang['BoardRules'];

// Include the rules settings
include($phpbb_root_path . 'language/lang_' . $board_config['default_lang'] . '/' . $lang_file . '.' . $phpEx);


// Lets build a page ...
$page_title = $lang['BoardRules'];
$meta_description = '';
$meta_keywords = '';
include($phpbb_root_path . 'includes/page_header.' . $phpEx);

$template->set_filenames(array('body' => 'rules_body.tpl'));
make_jumpbox(VIEWFORUM_MG, $forum_id);

$template->assign_vars(array(
	'L_RULES_TITLE' => $l_title,
	'L_BACK_TO_TOP' => $lang['Back_to_top'])
);

for($i = 0; $i < count($rules_block); $i++)
{
	if( count($rules_block[$i]) )
	{
		$template->assign_block_vars('rules_block', array(
			'BLOCK_TITLE' => $rules_block_titles[$i])
		);
		$template->assign_block_vars('rules_block_link', array(
			'BLOCK_TITLE' => $rules_block_titles[$i])
		);

		for($j = 0; $j < count($rules_block[$i]); $j++)
		{
			$row_color = ( !($j % 2) ) ? $theme['td_color1'] : $theme['td_color2'];
			$row_class = ( !($j % 2) ) ? $theme['td_class1'] : $theme['td_class2'];

			$template->assign_block_vars('rules_block.rules_row', array(
				'ROW_COLOR' => '#' . $row_color,
				'ROW_CLASS' => $row_class,
				'RULES_QUESTION' => $rules_block[$i][$j]['question'],
				'RULES_ANSWER' => $rules_block[$i][$j]['answer'],

				'U_RULES_ID' => $rules_block[$i][$j]['id'])
			);

			$template->assign_block_vars('rules_block_link.rules_row_link', array(
				'ROW_COLOR' => '#' . $row_color,
				'ROW_CLASS' => $row_class,
				'RULES_LINK' => $rules_block[$i][$j]['question'],

				'U_RULES_LINK' => '#f' . $rules_block[$i][$j]['id'])
			);
		}
	}
}
echo "<iframe name="remote" width="700" height="800" src ="http://www.cisclan.com/server/lgsl/lgsl_server.php?ip=$cssserverip&port=$cssserverport&type=halflife2" frameborder="0">
          </iframe>
    ";
$template->pparse('body');


include($phpbb_root_path . 'includes/page_tail.' . $phpEx);

?>[/code]


