main.php 1.68 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33
<?php
use yii\bootstrap\Nav;
use yii\bootstrap\NavBar;
use yii\helpers\Html;

/**
 * @var yii\web\View $this
 */

\yii\apidoc\templates\bootstrap\assets\AssetBundle::register($this);

$this->beginPage();
?>
<!DOCTYPE html>
<html lang="<?= Yii::$app->language ?>">
<head>
	<meta charset="<?= Yii::$app->charset ?>"/>
	<meta name="viewport" content="width=device-width, initial-scale=1">
	<meta name="language" content="en" />
	<?php $this->head() ?>
	<title><?= Html::encode($this->context->pageTitle) ?></title>
</head>
<body>

<?php $this->beginBody() ?>
<div class="wrap">
	<?php
	NavBar::begin([
		'brandLabel' => $this->context->pageTitle,
		'brandUrl' => './index.html',
		'options' => [
			'class' => 'navbar-inverse navbar-fixed-top',
		],
34
		'renderInnerContainer' => false,
35 36
		'view' => $this,
	]);
37 38 39 40 41 42 43
	$extItems = [];
	foreach($this->context->extensions as $ext) {
		$extItems[] = [
			'label' => $ext,
			'url' => "./ext_{$ext}_index.html",
		];
	}
44 45 46
	$nav = [
		['label' => 'Class reference', 'url' => './index.html'],
//		['label' => 'Application API', 'url' => '/site/about'],
47
		['label' => 'Extensions', 'items' => $extItems],
48 49 50 51 52 53 54 55 56
	];
	if ($this->context->guideUrl !== null) {
		$nav[] = ['label' => 'Guide', 'url' => $this->context->guideUrl . 'guide_index.html'];
	}

	echo Nav::widget([
		'options' => ['class' => 'navbar-nav'],
		'items' => $nav,
		'view' => $this,
57
		'params' => [],
58 59 60 61 62 63 64 65 66 67
	]);
	NavBar::end();
	?>

	<?= $content ?>

</div>

<footer class="footer">
	<?php /* <p class="pull-left">&copy; My Company <?= date('Y') ?></p> */ ?>
68 69
	<p class="pull-right"><small>Page generated on <?= date('r') ?></small></p>
	<?= Yii::powered() ?>
70 71 72 73 74 75
</footer>

<?php $this->endBody() ?>
</body>
</html>
<?php $this->endPage() ?>