Skip to content

Instantly share code, notes, and snippets.

View duythien's full-sized avatar
🏠
Working from home

Thien Tran duythien

🏠
Working from home
View GitHub Profile
@duythien
duythien / test.html
Last active September 20, 2016 02:22
http://5nines.phanbook.com/graphs/daily?key=287eeb0eea8a706c4614a16891f84e7b&id=3&date=20160726
https://admin.5nines.co.za//graphs/daily?key=rZL37hlI5oPK5ehw1tEY5OODR79INL7p&id=3&date=20160812
http://5nines.phanbook.com/graphs/daily?key=287eeb0eea8a706c4614a16891f84e7b&id=1&date=20160623
zend_extension=xdebug.so

xdebug.remote_enable = on
;xdebug.remote_connect_back = on
xdebug.idekey = "vagrant"
xdebug.remote_host="10.0.2.2"
xdebug.remote_autostart = on
xdebug.remote_log="/var/log/xdebug.log"
\documentclass{beamer}
%\usetheme[Boadilla]{Madrid}
\usetheme{CambridgeUS}
\makeatletter
\usepackage{ucs}
\usepackage{amsmath}
\usefonttheme[onlymath]{serif}
\usepackage{relsize}
\usepackage{wrapfig}
#!/usr/bin/env python
import os
import shutil
import pdb
import sqlite3 as lite #Library sqlite
from subprocess import PIPE, Popen, STDOUT
class classification:
root_dir = 'JavaBuildExample'
dest_dir = 'BuildedExample'
src_dir = 'JavaSourceCode'
@duythien
duythien / php_parks.md
Last active August 29, 2015 14:12 — forked from ryanj/php_parks.md

Open Source Mapping with PHP and MongoDB

In response to Steve's call for a shift toward civic-focused applications that are a better suited for adoption and maintenance by PHP-friendly IT departments, I've momentarily set aside OpenShift's shiny new nodejs-0.10 cartridge in order to show you how easy it is to write a basic single-page mapping application in PHP.

Those of you who are familiar with Steve's mapping quickstarts may recognize this application as a port of his own MongoDB-Python-Flask example which uses MongoDB's spatial features to perform a classic bounding-box query.

*Project source: [https://github.com/openshift-quickstart/silex-mongodb-pa

@duythien
duythien / gist:4d045c8d2f3844c471f2
Last active May 30, 2016 09:10
Install multiple Phalcon

In this particular post, we intend to offer a solution to install multiple versions of Phalcon, PHP and run them on a single web server. The PHP 5.5.x and 5.6.x will be used in here, but you can replace it with other versions. Any servers that support PHP-FPM should be enough but we recommend using the Nginx for the web server. The environment using in this tutorial is Fedora OS - a Linux system.

Preliminary Note

This tutorial will cover the installation of PHP 5.5.x correspoding Phalcon 1.3.x and PHP 5.6.x correspoding Phalcon 2.0.0. We also configuration some Nginx

Installing Nginx

Nginx is an available package in Fedora OS which we can install as follow:

###Send a pull request on GitHub for only latest commit

git checkout -b upstream upstream/master

git cherry-pick

git push origin upstream

@duythien
duythien / gist:cfd806c6ee28b10d5f0e
Created October 3, 2014 08:46
Multi version php
Configure: error: Cannot find openssl's <evp.h>
# yum install openssl-devel
Could not find pcre.h in /usr
# yum install pcre-devel