<?php echo $this->doctype; ?>
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?php echo $this->language; ?>" lang="<?php echo $this->language; ?>"<?php if ($this->isRTL): ?> dir="rtl"<?php endif; ?>>
<head>

  <?php $this->block('head'); ?>
    <meta http-equiv="Content-Type" content="text/html; charset=<?php echo $this->charset; ?>" />
    <title><?php echo $this->title; ?></title>
    <base href="<?php echo $this->base; ?>" />

    <?php $this->block('meta'); ?>
      <meta name="robots" content="<?php echo $this->robots; ?>" />
      <meta name="description" content="<?php echo $this->description; ?>" />
      <meta name="keywords" content="<?php echo $this->keywords; ?>" />
      <meta name="generator" content="Contao Open Source CMS" />
      <meta http-equiv="Content-Style-Type" content="text/css" />
      <meta http-equiv="Content-Script-Type" content="text/javascript" />
    <?php $this->endblock(); ?>

    <?php echo $this->viewport; ?>
    <?php echo $this->framework; ?>
    <?php echo $this->stylesheets; ?>
    <?php echo $this->mooScripts; ?>
    <?php echo $this->head; ?>
  <?php $this->endblock(); ?>

</head>
<body id="top" class="{{ua::class}}<?php if ($this->class) echo ' ' . $this->class; ?>"<?php if ($this->onload): ?> onload="<?php echo $this->onload; ?>"<?php endif; ?>>

  <?php $this->block('body'); ?>
    <?php $this->sections('top'); ?>

    <div id="wrapper">

      <?php $this->block('header'); ?>
        <?php if ($this->header): ?>
          <div id="header">
            <div class="inside">
              <?php echo $this->header; ?>
            </div>
          </div>
        <?php endif; ?>
      <?php $this->endblock(); ?>

      <?php $this->sections('before'); ?>

      <?php $this->block('container'); ?>
        <div id="container">

          <?php $this->block('main'); ?>
            <div id="main">
              <div class="inside">
                <?php echo $this->main; ?>
              </div>
              <?php $this->sections('main'); ?>
            </div>
          <?php $this->endblock(); ?>

          <?php $this->block('left'); ?>
            <?php if ($this->left): ?>
              <div id="left">
                <div class="inside">
                  <?php echo $this->left; ?>
                </div>
              </div>
            <?php endif; ?>
          <?php $this->endblock(); ?>

          <?php $this->block('right'); ?>
            <?php if ($this->right): ?>
              <div id="right">
                <div class="inside">
                  <?php echo $this->right; ?>
                </div>
              </div>
            <?php endif; ?>
          <?php $this->endblock(); ?>

        </div>
      <?php $this->endblock(); ?>

      <?php $this->sections('after'); ?>

      <?php $this->block('footer'); ?>
        <?php if ($this->footer): ?>
          <div id="footer">
            <div class="inside">
              <?php echo $this->footer; ?>
            </div>
          </div>
        <?php endif; ?>
      <?php $this->endblock(); ?>

    </div>

    <?php $this->sections('bottom'); ?>
  <?php $this->endblock(); ?>

  <?php echo $this->mootools; ?>

</body>
</html>