public static function get_top_level_templates()
	{

		$ss_templates_array = array();
		$current_theme_path = THEMES_PATH.'/'.Config::inst()->get('SSViewer', 'theme');

		//theme directories to search
		$search_dir_array = array(
			MAINTENANCE_MODE_PATH.'/templates',
			$current_theme_path.'/templates'
		);

		foreach ($search_dir_array as $directory) {

			//Get all the SS templates in the directory
			foreach (glob("{$directory}/*.ss") as $template_path) {

				//get the template name from the path excluding the ".ss" extension
				$template = basename($template_path, '.ss');

				//Add the key=>value pair to the ss_template_array
				$ss_templates_array[$template] = $template;
			}

		}

		return $ss_templates_array;

	}
public static function get_top_level_templates()
	{

		$ss_templates_array = array();
		$current_theme_path = THEMES_PATH.'/'.Config::inst()->get('SSViewer', 'theme');

		//theme directories to search
		$search_dir_array = array(
			MAINTENANCE_MODE_PATH.'/templates',
			$current_theme_path.'/templates'
		);

		foreach ($search_dir_array as $directory) {

			//Get all the SS templates in the directory
			foreach (glob("{$directory}/*.ss") as $template_path) {

				//get the template name from the path excluding the ".ss" extension
				$template = basename($template_path, '.ss');

				//Add the key=>value pair to the ss_template_array
				$ss_templates_array[$template] = $template;
			}

		}

		return $ss_templates_array;

	}
public static function get_top_level_templates ( ) { $ ss_templates_array = array ( ) ; $ current_theme_path = THEMES_PATH . '/' . Config :: inst ( ) -> get ( 'SSViewer' , 'theme' ) ; //theme directories to search $ search_dir_array = array ( MAINTENANCE_MODE_PATH . '/templates' , $ current_theme_path . '/templates' ) ; foreach ( $ search_dir_array as $ directory ) { //Get all the SS templates in the directory foreach ( glob ( "{$directory}/*.ss" ) as $ template_path ) { //get the template name from the path excluding the ".ss" extension $ template = basename ( $ template_path , '.ss' ) ; //Add the key=>value pair to the ss_template_array $ ss_templates_array [ $ template ] = $ template ; } } return $ ss_templates_array ; }
This function returns an array of top-level theme templates
@return array
This function returns an array of top - level theme templates