CoreThink主題開發(八)使用H-ui開發部落客題之使用者登入之前及登入之後

來源:互聯網
上載者:User
感謝H-ui、感謝CoreThink!



登入之後

登入表單

想做登入之後的下拉式功能表的,實在做不出來了,就一般顯示了。。。
整個麵包屑導航這裡,先遍曆模組,並且是允許前台顯示的模組,之後就是判斷使用者是否已經登入,已經登入了,就顯示個人中心,否則就顯示登入和註冊按鈕。
代碼:

<navclass="breadcrumb"><divclass="container"><spanclass="c-gray en"><iclass="Hui-iconfont">i><ahref="#">您好,歡迎來到 {:C('WEB_SITE_TITLE')} !a><opencmf:nav_listname="vo"pid="0"><atarget="{$vo.target}"href="{$vo.href}"><span> {$vo.title}span>a>opencmf:nav_list>span><presentname="_user_auth"><ahref="#" ><imgclass="round"src="{$_user_auth.avatar|get_cover='avatar'}"height="30px"width="30px"alt="{$_user_auth.nickname}" /><span>{$_user_auth.nickname}                           <span>                               {$_new_message}                           span>span><spanclass="caret">span>a><ahref="{:U('User/Index/home', array('uid' => $_user_auth['uid']), true, true)}"><spanclass="label label-secondary radius">個人首頁span>a><volistname="_user_nav_main"id="vo_nav"><ahref="{:U($vo_nav['url'], null, true, true)}"class="{$vo_nav.class}"><spanclass="label label-secondary radius">                            {$vo_nav.title}span>a>volist><ahref="{:U('User/User/logout', null, true, true)}"class="ajax-get"><spanclass="label label-danger radius">登出登入span>a><else/><aclass="btn btn-success-outline radius"data-toggle="modal"href="#register-modal">註冊a><aclass="btn btn-danger-outline radius"data-toggle="modal"href="#login-modal">登入a>present>div>nav>

Blog/Home/Public/layout.html

<html><head><metacharset="utf-8"><metaname="renderer"content="webkit|ie-comp|ie-stand"><metahttp-equiv="X-UA-Compatible"content="IE=edge"><metaname="viewport"content="width=device-width,initial-scale=1,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no"/><metahttp-equiv="Cache-Control"content="no-siteapp"/><linkrel="stylesheet"type="text/css"href="__HOME_CSS__/H-ui.min.css"/><linkrel="stylesheet"type="text/css"href="__HOME_LIBS__/Hui-iconfont/1.0.7/iconfont.css"/><linkrel="stylesheet"type="text/css"href="__HOME_LIBS__/icheck/icheck.css"/><linkrel="stylesheet"type="text/css"href="__HOME_CSS__/style.css"/><blockname="title"><title>{:C('WEB_SITE_TITLE')}title>block><metaname="keywords"content="關鍵詞,5個左右,單個8漢字以內"><metaname="description"content="網站描述,字數盡量空制在80個漢字,160個字元以內!">head><body><divclass="clearfix hook hook-page-header">    {:hook('PageHeader')} div><headerclass="navbar-wrapper"><divclass="navbar navbar-black navbar-fixed-top"><divclass="container cl"><aclass="logo navbar-logo hidden-xs"href="/aboutHui.shtml">{:C('WEB_SITE_TITLE')}a><aclass="logo navbar-logo-m visible-xs"href="/aboutHui.shtml">H-uia><spanclass="logo navbar-slogan hidden-xs">{:C('WEB_SITE_SLOGAN')}span><aaria-hidden="false"class="nav-toggle Hui-iconfont visible-xs"href="javascript:;">a><navclass="nav navbar-nav nav-collapse"role="navigation"id="Hui-navbar"><ulclass="cl"><li><ahref="{:C('HOME_PAGE')}">首頁a>li><cms:category_listname="vo"pid="0"group="1"><php>if($vo['_child']):php><liclass="dropDown dropDown_hover"><ahref="{$vo.href}"class="dropDown_A"data-toggle="dropdown"role="button">                                {$vo.title} <spanclass="caret">span>a><ulclass="dropDown-menu menu radius box-shadow"><volistname="vo._child"id="vo1"><li><ahref="{$vo1.href}">{$vo1.title}a>li>volist>ul>li><php>else:php><li><ahref="{$vo.href}"><span> {$vo.title}span>a>li><php>endif;php>cms:category_list>ul>nav><navclass="navbar-userbar hidden-xs">nav>div>div>header><navclass="breadcrumb"><divclass="container"><spanclass="c-gray en"><iclass="Hui-iconfont">i><ahref="#">您好,歡迎來到 {:C('WEB_SITE_TITLE')} !a><opencmf:nav_listname="vo"pid="0"><atarget="{$vo.target}"href="{$vo.href}"><span> {$vo.title}span>a>opencmf:nav_list>span><presentname="_user_auth"><ahref="#" ><imgclass="round"src="{$_user_auth.avatar|get_cover='avatar'}"height="30px"width="30px"alt="{$_user_auth.nickname}" /><span>{$_user_auth.nickname}                           <span>                               {$_new_message}                           span>span><spanclass="caret">span>a><ahref="{:U('User/Index/home', array('uid' => $_user_auth['uid']), true, true)}"><spanclass="label label-secondary radius">個人首頁span>a><volistname="_user_nav_main"id="vo_nav"><ahref="{:U($vo_nav['url'], null, true, true)}"class="{$vo_nav.class}"><spanclass="label label-secondary radius">                            {$vo_nav.title}span>a>volist><ahref="{:U('User/User/logout', null, true, true)}"class="ajax-get"><spanclass="label label-danger radius">登出登入span>a><else/><aclass="btn btn-success-outline radius"data-toggle="modal"href="#register-modal">註冊a><aclass="btn btn-danger-outline radius"data-toggle="modal"href="#login-modal">登入a>present>div>nav><blockname="main">block><footerclass="footer mt-20"><divclass="container"><p>{:C('WEB_SITE_COPYRIGHT')} <br><arel="nofollow"target="_blank"href="http://www.miitbeian.gov.cn/">                {:C('WEB_SITE_ICP')}            a>p>div>footer><scripttype="text/javascript"src="__HOME_LIBS__/jquery/1.9.1/jquery.min.js">script><scripttype="text/javascript"src="__HOME_LIBS__/layer/2.1/layer.js">script><scripttype="text/javascript"src="__HOME_LIBS__/laypage/1.2/laypage.js">script><scripttype="text/javascript"src="__HOME_LIBS__/My97DatePicker/WdatePicker.js">script><scripttype="text/javascript"src="__HOME_LIBS__/icheck/jquery.icheck.min.js">script><scripttype="text/javascript"src="__HOME_LIBS__/bootstrap-Switch/bootstrapSwitch.js">script><scripttype="text/javascript"src="__HOME_LIBS__/Validform/5.3.2/Validform.min.js">script><scripttype="text/javascript"src="__HOME_LIBS__/Validform/5.3.2/passwordStrength-min.js">script><scripttype="text/javascript"src="__HOME_JS__/H-ui.js">script><script>var navigation = responsiveNav("Hui-navbar", {customToggle: ".nav-toggle"});    $(function() {        $('.skin-minimal input').iCheck({            checkboxClass: 'icheckbox-blue',            radioClass: 'iradio-blue',            increaseArea: '20%'        });        $("#demoform").Validform({            tiptype: 2        });    });script>block><divclass="clearfix hook hook-page-footer">    {:hook('PageFooter')} div><includefile="$_user_login_modal"/><scripttype="text/javascript"src="__HOME_LIBS__/bootstrap-modal/2.2.4/bootstrap-modalmanager.js">script><scripttype="text/javascript"src="__HOME_LIBS__/bootstrap-modal/2.2.4/bootstrap-modal.js">script><blockname="script">block>body>html>

markdown 確實很好用

:)

').addClass('pre-numbering').hide(); $(this).addClass('has-numbering').parent().append($numbering); for (i = 1; i <= lines; i++) { $numbering.append($('
  • ').text(i)); }; $numbering.fadeIn(1700); }); });

    以上就介紹了CoreThink主題開發(八)使用H-ui開發部落客題之使用者登入之前及登入之後,包括了think,使用者登入方面的內容,希望對PHP教程有興趣的朋友有所協助。

  • 聯繫我們

    該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

    如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.