12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849 |
- <?php
- use yii\helpers\Url;
- use common\fm\Opencc;
- $module = Yii::$app->controller->module->id;
- if (!empty(Yii::$app->request->get('hid'))) {
- $name = \common\models\House::findOne(Yii::$app->request->get('hid'))['name'];
- $housenews = (new \common\models\News())->getHouseNews($name);
- }
- ?>
- <!-- 楼盘导航 -->
- <div style="height:25px;"></div>
- <div class="y_lpnav">
- <div class="y_lpnavmain puic_wid puic_color c">
- <ul class="c">
- <li <?php $hid = Yii::$app->request->get('hid'); if (strpos($_SERVER['REQUEST_URI'], 'house/' . $hid) > 0) echo 'class="on"' ?>>
- <a href="/house/<?= $hid ?>">
- <span><?= Opencc::ConvertHn('楼盘首页') ?></span>
- </a>
- </li>
- <li <?php if (strpos($_SERVER['REQUEST_URI'], 'house/details') > 0) echo 'class="on"' ?>>
- <a href="/house/details/<?= $hid ?>">
- <span><?= Opencc::ConvertHn('楼盘信息') ?></span>
- </a>
- </li>
- <?php if (!empty($housenews)) { ?>
- <li <?php if (strpos($_SERVER['REQUEST_URI'], 'house/news') > 0) echo 'class="on"' ?>>
- <a href="/house/news/<?= $hid ?>">
- <span><?= Opencc::ConvertHn('楼盘动态') ?></span>
- </a>
- </li>
- <?php } ?>
- <li <?php if (strpos($_SERVER['REQUEST_URI'], 'house/type') > 0) echo 'class="on"' ?>>
- <a href="/house/type/<?= $hid ?>">
- <span><?= Opencc::ConvertHn('楼盘户型') ?></span>
- </a>
- </li>
- <li <?php if (strpos($_SERVER['REQUEST_URI'], 'house/album') > 0) echo 'class="on"' ?>>
- <a href="/house/album/<?= $hid ?>">
- <span><?= Opencc::ConvertHn('楼盘相册') ?></span>
- </a>
- </li>
- </ul>
- </div>
- </div>
|