<?

	require_once "xslt/codegen/agents/_base.php";

	class CommonGenAgent extends BaseGenAgent
	{
		function CommonGenAgent()
		{}

		//
	 	// Process
		//
		
		function process($r)
		{
		}	

		function execute()
		{
			$d = array();
			$s = '';
			$i = 0;

			global $cat_db;
				
                        //
			// About
			//
			
			/*
			$filename = 'index.html';

			$s = $this->preprocess($filename,'index','О компании');
			$res = $cat_db->query("select * from about order by pos");
			$s .= "<dataset>";
			foreach($res as $r) {
				$s .= "<block>";
				if(strlen($r[photo]) > 2 && file_exists('../'.$r[photo])) $s .= "<photo>$r[photo]</photo>";	
				$s .= "<info>".xmlParseToHTML($r[info])."</info>";
				$s .= "</block>";
			};
			$s .= "</dataset>";

			$s .= $this->additions();
			$s .= $this->postprocess();
                        
				
		      	$d[$i] = new GenPage($filename);
			$d[$i]->applyXML($s);
			$i++;
                        */

			return $d;				
		}	
		
		function additions()
		{
			global $cat_db;
			return $s;
		}


	};

?>