Skip to content

Instantly share code, notes, and snippets.

@jaceju
jaceju / wp_converter.rb
Created October 30, 2011 16:31
WordPress To Octopress Markdown Converter
require 'fileutils'
require 'date'
require 'yaml'
require 'rexml/document'
require 'ya2yaml'
include REXML
doc = Document.new(File.new(ARGV[0]))
@jaceju
jaceju / create_zf_project.sh
Created November 3, 2011 02:58
利用專案樣版在 Subversion 中建立一個 Zend Framework 專案
#!/bin/bash
# Program:
# 利用專案樣版在 Subversion 中建立一個 Zend Framework 專案
# History:
# 2011/11/03 Jace Ju First release
# Usage:
# Create template of project at first time:
# > cd /path/to/project_template
# > mkdir branches
# > mkdir tags
@jaceju
jaceju / blog.sh
Created November 26, 2011 05:38
Octopress Blog Quick Operator
#!/bin/bash
# Author: Hsin-Yi Chen <ossug.hychen AT gmail.com>
# Modified: Jace Ju
# http://hychen.wuweig.org/blog/2011/11/13/huan-dao-octopress/
ERRMSG_WRONGDIR='You are not under octopress directory.'
[ ! -f _config.yml ] && echo ${ERRMSG_WRONGDIR} && exit
BLOGDIR=${PWD}
# Deploy contents
@jaceju
jaceju / aside_categories.rb
Created November 29, 2011 16:54
Aside Categories List Generator
# encoding: utf-8
#
# Aside categories list generator
#
# @author: jaceju
# @version: 0.0.1 alpha
module Jekyll
class Site
<?php
trait Singleton
{
protected static $_instance = null;
public static function getInstance()
{
if (static::$_instance === null
|| !(static::$_instance instanceof static)) {

PHP 高階技術課程

本課程共分做四天教授,目標對象為已有二到三年以上 PHP 專案開發經驗的 PHP 開發者。

Day 1

  • 物件導向基礎
  • PHP 5 特色與語法
<!doctype html>
<html>
<head>
<meta charset="utf-8" />
<title>Tab Example</title>
<link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.0.2/css/bootstrap.min.css"/>
</head>
<body>
<div id="demo" class="container">
<ul class="nav nav-tabs">
@jaceju
jaceju / index.html
Last active August 29, 2015 14:02
Use custom protocol to open KKBOX app on desktop or mobile.
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>App Redirection</title>
<!-- see https://gist.github.com/pulletsforever/2662899 -->
</head>
<body>
<iframe style="display:none" height="0" width="0" id="loader"></iframe>
<script>
@jaceju
jaceju / 0_reuse_code.js
Last active August 29, 2015 14:06
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@jaceju
jaceju / umd.js
Last active August 29, 2015 14:07
/*global define */
'use strict';
(function(root, factory) {
// Universal module definition
if (typeof define === 'function' && define.amd) {
define([
'react',
'backbone',
'underscore'
], factory);