<?php
	require_once( $GLOBALS["site_root"]."/includes/widgets/Widget.inc.php" );
	require_once( $GLOBALS["site_root"] . "/includes/widgets/Openads.inc.php" );
	require_once( $GLOBALS["site_root"] . "/includes/models/Globals.inc.php" );

	class Header extends Widget {

		public function __construct( $id = "Header" , $parent = null ) {
			parent::__construct( $id , $parent );
			switch ($GLOBALS["language"]) {
			default:
			case "hu": $zone_id = 73; break;
			case "en": $zone_id = 169; break;
			case "de": $zone_id = 184; break;
			}
			$this->oAdserver73 = new Openads( "adserver_73" , $this , $zone_id );
		}

		public function render() {
			if ($this->sRendered) return $this->sRendered;
			$this->setParam( "site_name" , GlobalsModel::getSiteName() );
			$this->setParam( "site_domain" , GlobalsModel::getSiteDomain() );
			return parent::render();
		}
	}
?>
