<?php
/**
 * Helpmain.php - The main help library that interfaces with various help config files
 *
 * @author $Author: dtong $
 * @version $Id: Helpmain.php,v 1.3 2011/02/11 12:51:20 dtong Exp $
 * @copyright Copyright (c) 2009, Tiller Software Co., Ltd.
*/

Class Helpmain {
	private $config = FALSE;

	function __construct($data) {
		if ( array_key_exists('config',$data) )
			$this->config = $data['config'];
	}

	function get_config() {
		if ( $this->config !== FALSE ) {
			if (include_once(CMS_TEMPLATEPATH_HELP . "help_{$this->config}.php")) {
				return help_config_data::get();
			}
		}
		return FALSE;
	}
}
?>