<?php use app\modules\admin\Module; use app\themes\admin\Theme; use app\themes\admin\widgets\Box; use yii\helpers\Url; use yii\web\View; /** * @var View $this * @var $modules array */ $this->title = Theme::t('title', 'Admin'); $this->params['subtitle'] = Theme::t('title', 'Site Preview'); $this->params['breadcrumbs'] = [$this->title]; $site = Module::siteUrl(); $js = <<<JS jQuery(function(\$) { var iframe = \$('iframe#sitepreview'); iframe.load(function () { var ifcontent = iframe.contents(); console.log('ifheight', iframe[0].contentWindow); iframe.height(ifcontent.height()); }); }); JS; $this->registerJs($js); ?> <div class="row"><div class="col-xs-12"> <?php Box::begin(['title' => $this->params['subtitle'], 'bodyOptions' => ['class' => 'no-padding']]);
<a href="#" class="dropdown-toggle" data-toggle="dropdown"> <!-- The user image in the navbar--> <img some-src="dist/img/user2-160x160.jpg" class="user-image" alt="User Image"/> <!-- hidden-xs hides the username on small devices so only the image appears. --> <span class="hidden-xs"><?php echo $name; ?> </span> </a> <ul class="dropdown-menu"> <li> <a href="#"><?php echo Theme::t('admin', 'Sign out'); ?> </a> </li> </ul> </li> <li> <a href="<?php echo Module::siteUrl(); ?> " target="_blank"><i class="fa fa-external-link"></i></a> </li> <!-- Control Sidebar Toggle Button --> <li> <a href="#" data-toggle="control-sidebar"><i class="fa fa-gears"></i></a> </li> </ul> </div>