Commit 2ad0080d authored by xiabin's avatar xiabin

承载页 title 规范

parent 36ea1e2b
<?php
/* @var $this yii\web\View */
$this->title=$classInfo['name'];
$this->registerMetaTag(['name' => 'keywords', 'content' => $classInfo['name']]);
\frontend\assets\AppAsset::addScript($this, '@web/assets/home_index.js');
\frontend\assets\AppAsset::addCss($this, '@web/assets/css/home_index.css');
\frontend\assets\AppAsset::addCss($this, '@web/assets/css/main.css');
?>
<input id="class-info" type="hidden" value="<?= \yii\helpers\Html::encode(json_encode($classInfo)) ?>"/>
......
......@@ -7,7 +7,9 @@
*/
use frontend\assets\AppAsset;
$this->title = "视频播放";
$this->registerMetaTag(['name' => 'keywords', 'content' => $coursewareInfo['className']]);
$this->registerMetaTag(['name' => 'description', 'content' => strip_tags(mb_substr($coursewareInfo['intro'],0,70))]);
$this->title = "{$coursewareInfo['courseName']}-{$coursewareInfo['className']}";
AppAsset::register($this);
$js = <<<JS
window._bd_share_config = {
......
......@@ -14,10 +14,8 @@ $baseUrl = \yii\helpers\Url::base();
<!DOCTYPE html>
<html>
<html lang="<?= Yii::$app->language ?>">
<title><?= $this->title ?></title>
<meta charset="<?= Yii::$app->charset ?>">
<meta name="description" content="">
<meta name="keywords" content="">
<meta name="copyright" content="云涯">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<link rel="shortcut icon" href="<?= AppAsset::getStaticUrl('img/favicon.ico') ?>">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment