<?php if(!defined('master_script')) die();

/**
 * Default data
 *
 * @category   Module (seo-content)
 * @author     Nico Wenig <nico.wenig@yellowgreen.de>
 * @version	   2010-06-08
 */
	
	$modules['seo-content']['version'] = '1.0';
	$modules['seo-content']['author'] = 'Nico Wenig';
	$modules['seo-content']['support'] = 'mailto:nico.wenig@yellowgreen.de';
	$modules['seo-content']['pagemap version'] = '0.5';
	$modules['seo-content']['for'] = 'all';
	$modules['seo-content']['key'] = 'seo-content';
	$modules['seo-content']['path'] = $system_data['folder']['modules'] . $modules['seo-content']['key'] . '/';
	$modules['seo-content']['languages'] = $system_data['folder']['modules'] . $modules['seo-content']['key'] . '/languages/';
	$modules['seo-content']['protected'] = 0;
	$modules['seo-content']['preview'] = 0;
	
	include_txt($modules['seo-content']['key'], $modules['seo-content']['languages']);

/**
 * Save module to page
 *
 * @category   Module (seo-content)
 * @author     Nico Wenig <nico.wenig@yellowgreen.de>
 * @version	   2009-12-21
 */

	if(isset($_POST['save_seo_content'])) {
		// Parse data
		
		// Create module section
		$module_content_to_save = '
			<!-- MODULE: seo-content -->
			
			<?php
				$module_settings["seo-content"] = array(
					"language" => "' . clean_string($_POST['language'], true) . '",
					"margin top" => ' . intval($_POST['margin_top']) . ',
					"margin left" => ' . intval($_POST['margin_left']) . ',
					"css class" => "' . clean_string($_POST['css_class'], true) . '",
					"css id" => "' . clean_string($_POST['css_id'], true) . '",
					"referer" =>' . intval($_POST['referer']) . ',
					"page name" => "' . $_POST['page_to_include'] . '",

					"referers" => "
						' . clean_string($_POST['referers']) . '
					",

					"text" => "
						' . strip_custom_tags($_POST['textfield'], true, false, true, false, false) . '
					"					
				);

				' . connector('seo-content backend save') . '
				include_module("seo-content");
			?>
		';
	}

?>