<?php
// $Id: header.php,v 1.6 2006/09/15 14:18:58 ohwada Exp $

// 2006-09-10 K.OHWADA
// use RSSC_HAPPY_LINUX_VERSION

// 2006-07-10 K.OHWADA
// require happy_linux module

// 2006-06-04 K.OHWADA
// this is new file

//================================================================
// Rss center Module
// 2006-06-04 K.OHWADA
//================================================================

// system files
include '../../mainfile.php';
include_once XOOPS_ROOT_PATH.'/class/snoopy.php';

if ( !file_exists(XOOPS_ROOT_PATH.'/modules/happy_linux/include/version.php') ) 
{
	include XOOPS_ROOT_PATH.'/header.php';
	xoops_error( 'require happy_linux module' );
	include XOOPS_ROOT_PATH.'/footer.php';
	exit();
}

include_once XOOPS_ROOT_PATH.'/modules/happy_linux/include/version.php';
include_once XOOPS_ROOT_PATH.'/modules/happy_linux/include/functions.php';
include_once XOOPS_ROOT_PATH.'/modules/happy_linux/include/multibyte.php';
include_once XOOPS_ROOT_PATH.'/modules/happy_linux/include/search.php';
include_once XOOPS_ROOT_PATH.'/modules/happy_linux/api/language.php';
include_once XOOPS_ROOT_PATH.'/modules/happy_linux/class/error.php';
include_once XOOPS_ROOT_PATH.'/modules/happy_linux/class/strings.php';
include_once XOOPS_ROOT_PATH.'/modules/happy_linux/class/highlight.php';
include_once XOOPS_ROOT_PATH.'/modules/happy_linux/class/post.php';
include_once XOOPS_ROOT_PATH.'/modules/happy_linux/class/system.php';
include_once XOOPS_ROOT_PATH.'/modules/happy_linux/class/remote_file.php';
include_once XOOPS_ROOT_PATH.'/modules/happy_linux/class/convert_encoding.php';
include_once XOOPS_ROOT_PATH.'/modules/happy_linux/class/pagenavi.php';
include_once XOOPS_ROOT_PATH.'/modules/happy_linux/class/search.php';
include_once XOOPS_ROOT_PATH.'/modules/happy_linux/class/basic_handler.php';
include_once XOOPS_ROOT_PATH.'/modules/happy_linux/class/object.php';
include_once XOOPS_ROOT_PATH.'/modules/happy_linux/class/object_handler.php';

// dir name
if( !defined('RSSC_DIRNAME') )
{
	define('RSSC_DIRNAME', $xoopsModule->dirname() );
}

if( !defined('RSSC_ROOT_PATH') )
{
	define('RSSC_ROOT_PATH', XOOPS_ROOT_PATH.'/modules/'.RSSC_DIRNAME );
}

if( !defined('RSSC_URL') )
{
	define('RSSC_URL', XOOPS_URL.'/modules/'.RSSC_DIRNAME );
}

// module files
include_once RSSC_ROOT_PATH.'/include/rssc_version.php';
include_once RSSC_ROOT_PATH.'/include/rssc_constant.php';
include_once RSSC_ROOT_PATH.'/include/rssc_get_handler.php';
include_once RSSC_ROOT_PATH.'/class/rssc_config_basic_handler.php';
include_once RSSC_ROOT_PATH.'/class/rssc_link_handler.php';
include_once RSSC_ROOT_PATH.'/class/rssc_feed_handler.php';
include_once RSSC_ROOT_PATH.'/class/rssc_xml_utility.php';
include_once RSSC_ROOT_PATH.'/class/rssc_xml_object.php';
include_once RSSC_ROOT_PATH.'/class/rssc_view_param.php';

global $xoopsConfig;
$XOOPS_LANGUAGE = $xoopsConfig['language'];

// system search
if ( file_exists(XOOPS_ROOT_PATH.'/language/'.$XOOPS_LANGUAGE.'/search.php') ) 
{
	include_once XOOPS_ROOT_PATH.'/language/'.$XOOPS_LANGUAGE.'/search.php';
}
else
{
	include_once XOOPS_ROOT_PATH.'/language/english/search.php';
}

// compatible
include_once RSSC_ROOT_PATH.'/language/compatible.php';

// check happy_linux version
if ( HAPPY_LINUX_VERSION < RSSC_HAPPY_LINUX_VERSION ) 
{
	$msg = 'require happy_linux module v'.RSSC_HAPPY_LINUX_VERSION.' or later';
	include XOOPS_ROOT_PATH.'/header.php';
	xoops_error( $msg );
	include XOOPS_ROOT_PATH.'/footer.php';
	exit();
}

?>