---
layout: false
---

<!DOCTYPE html>
<html lang="zh-cmn-Hans">

<!-- Head tag -->
<%- partial('_partial/head') %>

<!-- hack iOS CSS :active style -->

<body ontouchstart="">

    <!-- Page Header -->
    <%- partial('_partial/nav') %>

    <!-- Post Header -->
    <style type="text/css">
        header.intro-header {
            height: 500px;
            overflow: hidden;
        }

        header iframe {
            width: 100%;
            height: 100%;
            border: 0;
        }
    </style>
    <header class="intro-header">
        <iframe src="<%= page.iframe %>">
            <div class="container">
                <div class="row">
                    <div class="col-lg-8 col-lg-offset-2 col-md-10 col-md-offset-1">
                        <div class="post-heading">
                            <div class="tags">
                                <% page.tags.forEach(function(tag){ %>
                                <a class="tag" href="<%= config.root %><%= tag.path %>"
                                    title="<%= tag.name %>"><%= tag.name %></a>
                                <% }) %>
                            </div>

                            <h1><%= page.title %></h1>
                            <h2 class="subheading"><%= page.subtitle %></h2>
                            <span class="meta">
                                Posted by <%- page.author || config.author %> on
                                <%= page.date.format(config.date_format) %>
                            </span>

                        </div>
                    </div>
                </div>
            </div>
        </iframe>
    </header>

    <!-- Post Content -->
    <article>
        <div class="container">
            <div class="row">

                <!-- Post Container -->
                <div class="
                    col-lg-8 col-lg-offset-2
                    col-md-10 col-md-offset-1
                    post-container">

                    <%- page.content %>

                    <hr>

                    <% if(config['duoshuo_share'] && config['duoshuo_username']) { %>
                    <!-- 多说 Share start -->
                    </style>
                    <div class="ds-share" style="text-align: right" data-thread-key="<%= page.path %>"
                        data-title="<%= page.title %>" data-url="<%= page.permalink %>"
                        data-images="<%= config.url %><%= config.root %><%= page["header-img"] || config["header-img"] %>"
                        data-content="<%- truncate(strip_html(page.content), {length: 50, omission: '...'}) %> | <%= config.SEOTitle %> ">
                        <div class="ds-share-inline">
                            <ul class="ds-share-icons-16">
                                <li data-toggle="ds-share-icons-more"><a class="ds-more" href="#">分享到：</a></li>
                                <li><a class="ds-wechat flat" href="javascript:void(0);" data-service="wechat">微信</a>
                                </li>
                                <li><a class="ds-weibo flat" href="javascript:void(0);" data-service="weibo">微博</a></li>
                                <li><a class="ds-douban flat" href="javascript:void(0);" data-service="douban">豆瓣</a>
                                </li>
                            </ul>
                            <div class="ds-share-icons-more">
                            </div>
                        </div>
                        <hr>
                    </div>
                    <!-- 多说 Share end-->
                    <% } %>

                    <ul class="pager">
                        <% if (page.prev){ %>
                        <li class="previous">
                            <a href="<%- config.root %><%- page.prev_link %>" data-toggle="tooltip" data-placement="top"
                                title="<%- page.prev.title %>">&larr; Previous Post</a>
                        </li>
                        <% } %>
                        <% if (page.next){ %>
                        <li class="next">
                            <a href="<%- config.root %><%- page.next_link %>" data-toggle="tooltip" data-placement="top"
                                title="<%- page.next.title %>">Next Post &rarr;</a>
                        </li>
                        <% } %>
                    </ul>

                    <% if(config['duoshuo_username']) { %>
                    <!-- 多说评论框 start -->
                    <div class="comment">
                        <div class="ds-thread" data-thread-key="<%= page.path %>" data-title="<%= page.title %>"
                            data-url="<%= page.permalink %>">
                        </div>
                    </div>
                    <!-- 多说评论框 end -->
                    <% } %>

                    <% if(config['disqus_username']) { %>
                    <!-- disqus 评论框 start -->
                    <div class="comment">
                        <div id="disqus_thread" class="disqus-thread"></div>
                    </div>
                    <!-- disqus 评论框 end -->
                    <% } %>

                </div>

                <!-- Sidebar Container -->

                <div class="
                    col-lg-8 col-lg-offset-2
                    col-md-10 col-md-offset-1
                    sidebar-container">

                    <!-- Featured Tags -->
                    <% if(config['featured-tags']) { %>
                    <section>
                        <!-- no hr -->
                        <h5><a href="<%= config.root %>tags/">FEATURED TAGS</a></h5>
                        <div class="tags">
                            <%- list_tags({style: '', class: '', show_count: false, separator: ''}) %>
                        </div>
                    </section>
                    <% }%>

                    <!-- Friends Blog -->
                    <% if(config.friends) { %>
                    <hr>
                    <h5>FRIENDS</h5>
                    <ul class="list-inline">

                        <% config.friends.forEach(function(friend){ %>
                        <li><a href="<%= friend.href %>"><%= friend.title %></a></li>
                        <% }); %>
                    </ul>
                    <% }%>
                </div>

            </div>
        </div>
    </article>

    <% if(config['duoshuo_username']) { %>
    <!-- 多说公共JS代码 start (一个网页只需插入一次) -->
    <script type="text/javascript">
        // dynamic User by Hux
        var _user = '<%= config['duoshuo_username'] %>';

        // duoshuo comment query.
        var duoshuoQuery = { short_name: _user };
        (function () {
            var ds = document.createElement('script');
            ds.type = 'text/javascript'; ds.async = true;
            ds.src = (document.location.protocol == 'https:' ? 'https:' : 'http:') + '//static.duoshuo.com/embed.js';
            ds.charset = 'UTF-8';
            (document.getElementsByTagName('head')[0]
                || document.getElementsByTagName('body')[0]).appendChild(ds);
        })();
    </script>
    <!-- 多说公共JS代码 end -->
    <% } %>

    <% if(config['disqus_username']) { %>
    <!-- disqus 公共JS代码 start (一个网页只需插入一次) -->
    <script type="text/javascript">
        /* * * CONFIGURATION VARIABLES * * */
        var disqus_shortname = "<%= config['disqus_username'] %>";
        var disqus_identifier = "<%= page.permalink %>";
        var disqus_url = "<%= page.permalink %>";

        (function () {
            var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
            dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
            (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
        })();
    </script>
    <!-- disqus 公共JS代码 end -->
    <% } %>

    <!-- Footer -->
    <%- partial('_partial/footer') %>

</body>

</html>
