Coder Social home page Coder Social logo

lighthalzen's Introduction

Lighthalzen

학과 사무실에 의해 프로젝트가 영구 중단되었습니다. 개발이 완료되지 않은 프로젝트이지만 미래의 내가 PHP 개발 혹은 워드프레스 테마 공부를 할 때 참고할 수 있도록 기록을 남겨둡니다.

연구실 홈페이지에 적용되었습니다. https://monet.postech.ac.kr

Installation

Do git clone https://github.com/yuoa/lighthalzen on wp-contents/themes directory.

There's some additional php packages, so you may install Composer and type composer update on the root directory of this theme.
There's some additional npm packages, so you may install npm and type npm i on the root directory of this theme.
There's some required package, so install packages below.

WordPress Configuration

Bilingual Plugin

Lighthalzen uses qTranslate X to support bilingual post management. You must config qTranslate X as below.

General

  • Default Language / Order

    Language Code Flag Name Locale Date Format Time Format Not Available Message
    ko kr.jpg 한글 ko %Y년 %B %e일 %A %I:%M %p 이 문서는 %LANG:, :, %로만 제공됩니다.
    en gb.jpg English en %A %B %e%q, %Y %I:%M %p Sorry, this page is only available in %LANG%:, : and %.
  • URL Modification Mode

    • Select Use Pre-Path Mode (Default, puts /en/ in front of URL). SEO friendly.
    • Uncheck Hide URL language information for default language.
  • Untranslated Content
    Check ONLY Show content in an alternative language when translation is not available for the selected language.

  • Detect Browser Language
    Check Detect the language of the browser and redirect accordingly.

Advanced

  • Head inline CSS
    Uncheck this option.

  • Cookie Settings

    • Uncheck Disable language client cookie "~" (not recommended).
    • Check Make qTranslate‑X cookies available only through HTTPS connections.

Plugin Source Edit

  • For uniform language cookie name, edit qtranslate_options.php as below.

    <?php ...
    
    // From
    define('QTX_COOKIE_NAME_FRONT','qtrans_front_language');
    
    // To
    define('QTX_COOKIE_NAME_FRONT', 'rimi');
    
    ... ?>
  • For stylized alternative language message, edit qtranslate_core.php as below.

    <?php ...
    
    // From
    $output = '<p class="qtranxs-available-languages-message qtranxs-available-languages-message-'.$lang.'">'.preg_replace('/%LANG:([^:]*):([^%]*)%/', $language_list, $q_config['not_available'][$lang]).$altlanguagecontent;
    
    // To
    $output = '<p class="nolang-disclaimer">'.preg_replace('/%LANG:([^:]*):([^%]*)%/', $language_list, $q_config['not_available'][$lang]).$altlanguagecontent;
    
    ... ?>

Post Permalink

Use custom permalink structure as /%category%/%post_id%/%postname%/.

User Role

Roles below are necessary to make theme work normally.

  • cite-managers : User who has this role will be able to edit theme configurations. (Admins can access to setting page by default.)

About Stylesheet (sass)

Lighthalzen uses sass to make stylesheet easier. Refer to Sass homepage for more information.

How to change .scss files to style.css

In lighthalzen directory, you can type sass --sourcemap=none --watch scss/style.scss:style.css --style compressed to continuously build whole scss files into style.css.

Server Access Configuration

For mental peace, check your web server configuration to hide .scss and .md files.
I also recommend you to check hiding of .sass-cache and .git directory.

About Translation (i18n)

Lighthalzen supports Korean and English using gettext from GNU project, and google translation.

gettext

gettext is application localization project of GNU project.
i18n/ko.po, i18n/ko.mo is related with gettext.
You can edit/translate these files with POEDIT.

Google Translation

If there is any important part which is not translated, lighthalzen translates it automatically using google translation. This google translation feature is managed by stichoza/google-translate-php.

License

Lighthalzen is licensed under CiTE License 1.0. Check LICENSE.md for detail.

lighthalzen's People

Contributors

wldhg avatar

Watchers

 avatar

lighthalzen's Issues

PHP Warning: count(): Parameter must be an array or an object that implements Countable in ~/wp-includes/post-template.php on line 284

Issue page: https://cite.dev.yuoa.pm/post/2018/07/31/example/

Warning: count(): Parameter must be an array or an object that implements Countable in ~/wp-includes/post-template.php on line 284

--- SOURCE CODE ---

<!doctype html>
<html lang="ko-KR"><head>
    <style type="text/css">/*
 * contextMenu.js v 1.4.0
 * Author: Sudhanshu Yadav
 * s-yadav.github.com
 * Copyright (c) 2013 Sudhanshu Yadav.
 * Dual licensed under the MIT and GPL licenses
**/

.iw-contextMenu {
    box-shadow: 0px 2px 3px rgba(0, 0, 0, 0.10);
    border: 1px solid #c8c7cc;
    border-radius: 11px;
    display: none;
    z-index: 1000000132;
    max-width: 300px;
}

.iw-cm-menu {
    background: #fff;
    color: #000;
    margin: 0px;
    padding: 0px;
}

.iw-curMenu {
}

.iw-cm-menu li {
    font-family: -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, Arial, Ubuntu, sans-serif;
    list-style: none;
    padding: 10px;
    padding-right: 20px;
    border-bottom: 1px solid #c8c7cc;
    cursor: pointer;
    position: relative;
    font-size: 14px;
    margin: 0;
    line-height: inherit;
}

.iw-cm-menu li:first-child {
    border-top-left-radius: 11px;
    border-top-right-radius: 11px;
}

.iw-cm-menu li:last-child {
    border-bottom-left-radius: 11px;
    border-bottom-right-radius: 11px;
    border-bottom: none;
}

.iw-mOverlay {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0px;
    left: 0px;
    background: #FFF;
    opacity: .5;
}

.iw-contextMenu li.iw-mDisable {
    opacity: 0.3;
    cursor: default;
}

.iw-mSelected {
    background-color: #F6F6F6;
}

.iw-cm-arrow-right {
    width: 0;
    height: 0;
    border-top: 5px solid transparent;
    border-bottom: 5px solid transparent;
    border-left: 5px solid #000;
    position: absolute;
    right: 5px;
    top: 50%;
    margin-top: -5px;
}

.iw-mSelected > .iw-cm-arrow-right {
}

/*context menu css end */</style><style type="text/css">@-webkit-keyframes load4 {
    0%,
    100% {
        box-shadow: 0 -3em 0 0.2em, 2em -2em 0 0em, 3em 0 0 -1em, 2em 2em 0 -1em, 0 3em 0 -1em, -2em 2em 0 -1em, -3em 0 0 -1em, -2em -2em 0 0;
    }
    12.5% {
        box-shadow: 0 -3em 0 0, 2em -2em 0 0.2em, 3em 0 0 0, 2em 2em 0 -1em, 0 3em 0 -1em, -2em 2em 0 -1em, -3em 0 0 -1em, -2em -2em 0 -1em;
    }
    25% {
        box-shadow: 0 -3em 0 -0.5em, 2em -2em 0 0, 3em 0 0 0.2em, 2em 2em 0 0, 0 3em 0 -1em, -2em 2em 0 -1em, -3em 0 0 -1em, -2em -2em 0 -1em;
    }
    37.5% {
        box-shadow: 0 -3em 0 -1em, 2em -2em 0 -1em, 3em 0em 0 0, 2em 2em 0 0.2em, 0 3em 0 0em, -2em 2em 0 -1em, -3em 0em 0 -1em, -2em -2em 0 -1em;
    }
    50% {
        box-shadow: 0 -3em 0 -1em, 2em -2em 0 -1em, 3em 0 0 -1em, 2em 2em 0 0em, 0 3em 0 0.2em, -2em 2em 0 0, -3em 0em 0 -1em, -2em -2em 0 -1em;
    }
    62.5% {
        box-shadow: 0 -3em 0 -1em, 2em -2em 0 -1em, 3em 0 0 -1em, 2em 2em 0 -1em, 0 3em 0 0, -2em 2em 0 0.2em, -3em 0 0 0, -2em -2em 0 -1em;
    }
    75% {
        box-shadow: 0em -3em 0 -1em, 2em -2em 0 -1em, 3em 0em 0 -1em, 2em 2em 0 -1em, 0 3em 0 -1em, -2em 2em 0 0, -3em 0em 0 0.2em, -2em -2em 0 0;
    }
    87.5% {
        box-shadow: 0em -3em 0 0, 2em -2em 0 -1em, 3em 0 0 -1em, 2em 2em 0 -1em, 0 3em 0 -1em, -2em 2em 0 0, -3em 0em 0 0, -2em -2em 0 0.2em;
    }
}

@keyframes load4 {
    0%,
    100% {
        box-shadow: 0 -3em 0 0.2em, 2em -2em 0 0em, 3em 0 0 -1em, 2em 2em 0 -1em, 0 3em 0 -1em, -2em 2em 0 -1em, -3em 0 0 -1em, -2em -2em 0 0;
    }
    12.5% {
        box-shadow: 0 -3em 0 0, 2em -2em 0 0.2em, 3em 0 0 0, 2em 2em 0 -1em, 0 3em 0 -1em, -2em 2em 0 -1em, -3em 0 0 -1em, -2em -2em 0 -1em;
    }
    25% {
        box-shadow: 0 -3em 0 -0.5em, 2em -2em 0 0, 3em 0 0 0.2em, 2em 2em 0 0, 0 3em 0 -1em, -2em 2em 0 -1em, -3em 0 0 -1em, -2em -2em 0 -1em;
    }
    37.5% {
        box-shadow: 0 -3em 0 -1em, 2em -2em 0 -1em, 3em 0em 0 0, 2em 2em 0 0.2em, 0 3em 0 0em, -2em 2em 0 -1em, -3em 0em 0 -1em, -2em -2em 0 -1em;
    }
    50% {
        box-shadow: 0 -3em 0 -1em, 2em -2em 0 -1em, 3em 0 0 -1em, 2em 2em 0 0em, 0 3em 0 0.2em, -2em 2em 0 0, -3em 0em 0 -1em, -2em -2em 0 -1em;
    }
    62.5% {
        box-shadow: 0 -3em 0 -1em, 2em -2em 0 -1em, 3em 0 0 -1em, 2em 2em 0 -1em, 0 3em 0 0, -2em 2em 0 0.2em, -3em 0 0 0, -2em -2em 0 -1em;
    }
    75% {
        box-shadow: 0em -3em 0 -1em, 2em -2em 0 -1em, 3em 0em 0 -1em, 2em 2em 0 -1em, 0 3em 0 -1em, -2em 2em 0 0, -3em 0em 0 0.2em, -2em -2em 0 0;
    }
    87.5% {
        box-shadow: 0em -3em 0 0, 2em -2em 0 -1em, 3em 0 0 -1em, 2em 2em 0 -1em, 0 3em 0 -1em, -2em 2em 0 0, -3em 0em 0 0, -2em -2em 0 0.2em;
    }
}</style><style type="text/css">/* This is not a zero-length file! */</style></head><body id="begin"><br>
<b>Warning</b>:  count(): Parameter must be an array or an object that implements Countable in <b>/web/cite/wp-includes/post-template.php</b> on line <b>284</b><br>
<meta name="author" content="Saaya">
<meta name="description" content="">
<meta property="og:title" content="example - 창의IT융합공학과">
<meta property="og:url" content="https://cite.dev.yuoa.pm/post/2018/07/31/example/">
<meta property="og:image" content="https://cite.dev.yuoa.pm/wp-content/themes/lighthalzen/static/banner.png">
<meta property="og:description" content="">
<title>example - 창의IT융합공학과</title>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, user-scalable=no">
<meta name="theme-color" content="#000737">
<link href="https://cite.dev.yuoa.pm/wp-content/themes/lighthalzen/style.css" rel="stylesheet">
<link href="https://cite.dev.yuoa.pm/wp-content/themes/lighthalzen/static/favicon.ico" rel="shortcut icon">
<meta name="robots" content="noindex,follow">
<link rel="dns-prefetch" href="//s.w.org">
<link rel="alternate" type="application/rss+xml" title="창의IT융합공학과 » example 댓글 피드" href="https://cite.dev.yuoa.pm/post/2018/07/31/example/feed/">
<style type="text/css">
img.wp-smiley,
img.emoji {
	display: inline !important;
	border: none !important;
	box-shadow: none !important;
	height: 1em !important;
	width: 1em !important;
	margin: 0 .07em !important;
	vertical-align: -0.1em !important;
	background: none !important;
	padding: 0 !important;
}
</style>
<link rel="https://api.w.org/" href="https://cite.dev.yuoa.pm/wp-json/">
<link rel="EditURI" type="application/rsd+xml" title="RSD" href="https://cite.dev.yuoa.pm/xmlrpc.php?rsd">
<link rel="wlwmanifest" type="application/wlwmanifest+xml" href="https://cite.dev.yuoa.pm/wp-includes/wlwmanifest.xml"> 
<link rel="prev" title="Hello world!" href="https://cite.dev.yuoa.pm/post/2018/07/27/hello-world/">

<link rel="canonical" href="https://cite.dev.yuoa.pm/post/2018/07/31/example/">
<link rel="shortlink" href="https://cite.dev.yuoa.pm/?p=26">
<link rel="alternate" type="application/json+oembed" href="https://cite.dev.yuoa.pm/wp-json/oembed/1.0/embed?url=https%3A%2F%2Fcite.dev.yuoa.pm%2Fpost%2F2018%2F07%2F31%2Fexample%2F">
<link rel="alternate" type="text/xml+oembed" href="https://cite.dev.yuoa.pm/wp-json/oembed/1.0/embed?url=https%3A%2F%2Fcite.dev.yuoa.pm%2Fpost%2F2018%2F07%2F31%2Fexample%2F&amp;format=xml">


    <header id="top">
    <div class="identity">
        <a href="https://cite.dev.yuoa.pm" target="_self">
            <img src="https://cite.dev.yuoa.pm/wp-content/themes/lighthalzen/image/[email protected]" alt="창의IT융합공학과 로고">
        </a>
    </div>
    <nav id="nav" class="navigator"><ul><li tabindex="1"><a href="https://cite.dev.yuoa.pm/">CiTE</a><ul><li tabindex="2"><a href="https://cite.dev.yuoa.pm/">주임교수 인사말</a></li><li tabindex="3"><a href="https://cite.dev.yuoa.pm/post/2018/07/31/example/">ICT명품인재양성사업</a></li><li tabindex="4"><a href="https://cite.dev.yuoa.pm/post/2018/07/27/hello-world/">교육 철학과 체계</a></li><li tabindex="5"><a href="https://cite.dev.yuoa.pm/post/2018/07/31/example/">협력기관</a></li><li tabindex="6"><a href="https://cite.dev.yuoa.pm/post/2018/07/27/hello-world/">조직도</a></li><li tabindex="7"><a href="https://cite.dev.yuoa.pm/post/2018/07/31/example/">찾아오시는 길</a></li><li tabindex="8"><a href="https://cite.dev.yuoa.pm/post/2018/07/27/hello-world/">홍보 자료</a></li></ul></li><li tabindex="9"><a href="https://cite.dev.yuoa.pm/">구성원 소개</a><ul><li tabindex="10"><a href="https://cite.dev.yuoa.pm/">교수</a></li><li tabindex="11"><a href="https://cite.dev.yuoa.pm/">전임 연구원</a></li><li tabindex="12"><a href="https://cite.dev.yuoa.pm/category/post/">직원</a></li></ul></li><li tabindex="13"><a href="https://cite.dev.yuoa.pm/">학과 소식</a><ul><li tabindex="14"><a href="https://cite.dev.yuoa.pm/post/2018/07/31/example/">공지사항</a></li><li tabindex="15"><a href="https://cite.dev.yuoa.pm/post/2018/07/27/hello-world/">입학정보</a></li><li tabindex="16"><a href="https://cite.dev.yuoa.pm/post/2018/07/31/example/">채용정보</a></li><li tabindex="17"><a href="https://cite.dev.yuoa.pm/post/2018/07/27/hello-world/">세미나 및 행사</a></li><li tabindex="18"><a href="https://cite.dev.yuoa.pm/post/2018/07/31/example/">뉴스레터</a></li><li tabindex="19"><a href="https://cite.dev.yuoa.pm/post/2018/07/27/hello-world/">갤러리</a></li><li tabindex="20"><a href="https://cite.dev.yuoa.pm/post/2018/07/31/example/">학과 자료실</a></li><li tabindex="21"><a href="https://cite.dev.yuoa.pm/post/2018/07/27/hello-world/">Hello world!</a></li></ul></li><li tabindex="22"><a href="https://cite.dev.yuoa.pm/">연구</a><ul><li tabindex="23"><a href="https://cite.dev.yuoa.pm/">연구 분야</a></li><li tabindex="24"><a href="https://cite.dev.yuoa.pm/post/2018/07/31/example/">연구 실적</a></li><li tabindex="25"><a href="https://cite.dev.yuoa.pm/post/2018/07/27/hello-world/">연구장비 현황</a></li><li tabindex="26"><a href="https://cite.dev.yuoa.pm/">대여가능 연구장비</a></li></ul></li><li tabindex="27"><a href="https://cite.dev.yuoa.pm/">Creative US!</a></li></ul></nav>    <div class="button-box">
        <button class="search">
            <a href="">
                <img src="https://cite.dev.yuoa.pm/wp-content/themes/lighthalzen/image/[email protected]" alt="검색 아이콘">
                <span>검색</span>
            </a>
        </button>
        <button class="language">
            <a href="/post/2018/07/31/example/?lang=en">
                <img src="https://cite.dev.yuoa.pm/wp-content/themes/lighthalzen/image/[email protected]" alt="English mode icon">
                <span>English</span>
            </a>
        </button>
        <button class="menu">
            <a href="#nav">
                <img src="https://cite.dev.yuoa.pm/wp-content/themes/lighthalzen/image/[email protected]" alt="메뉴 아이콘">
                <span>메뉴</span>
            </a>
        </button>
    </div>
    <article class="slider">
    <style>
        section.slide[data-num="0"] { background-image: url(https://cite.dev.yuoa.pm/wp-content/themes/lighthalzen/image/[email protected]); }
    </style>
    <section data-num="0" class="slide">
        <div class="text-box">
            <h1>창공인의 요람 C5, 리모델링 완료</h1>
            <p>2015년부터 창의공간을 대신하여 사용해오던 C5 1층 학부생 공간이 3년만에 리모델링되었습니다.</p>
            <a href="">더보기</a>
        </div>
    </section>
</article>
</header>
    <span>Contents</span>
    

</body></html>

Uncaught TypeError: (event.target.className || "").indexOf is not a function

Describe the bug
When I doubleclick on top button box, an error appears on Javascript console.

To Reproduce
Do doubleclick on top button box

Expected behavior
No error on doubleclick

Screenshots or Page HTML code

Uncaught TypeError: (event.target.className || "").indexOf is not a function
    at onDoubleClick (eval at success (kernel.js:209), <anonymous>:62:48)
    at dispatch (jquery.js:3)
    at r.handle (jquery.js:3)
onDoubleClick @ VM8418:62
dispatch @ jquery.js:3
r.handle @ jquery.js:3

Desktop (please complete the following information):

  • Browser: Chrome
  • Version: 70.0.3518.0 (Official) canary (64bit) (cohort: Clang-64)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.