Skip to content

Instantly share code, notes, and snippets.

Giap Nguyen nvg58

Block or report user

Report or block nvg58

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@nvg58
nvg58 / install_mysql.sh
Created Nov 12, 2015 — forked from rrosiek/install_mysql.sh
Vagrant provision script for php, Apache, MySQL, phpMyAdmin, Laravel, and javascript helpers. Outputs nearly everything to /dev/null since "quiet" on most commands is still noisy.
View install_mysql.sh
#! /usr/bin/env bash
# Variables
APPENV=local
DBHOST=localhost
DBNAME=dbname
DBUSER=dbuser
DBPASSWD=test123
echo -e "\n--- Mkay, installing now... ---\n"
@nvg58
nvg58 / ymltosql.php
Last active Aug 29, 2015
Convert YML to MySQL
View ymltosql.php
<?php
// Modified from http://sumanrs.wordpress.com/2012/02/23/yaml-to-mysql-yaml2sql-script-in-php
// Connect SQL
$servername = "localhost";
$username = "root";
$password = "root";
$database = "test";
// Create connection
View portal.py
import requests
host = 'http://dangkyhoc.daotao.vnu.edu.vn/dang-nhap'
#studentID = ''
#passw = ''
def check(studentID, passw):
payload = {'LoginName': studentID, 'Password': passw, '__RequestVerificationToken': 'e4dBmzKQN245hMpLnjwX19efdikITAR39gf7dl1WjKk-PVrQ1WxdcQxjYJTf8N8JsecCb5QnIsr4VGSKQr8N51vUlkk1'}
View dimox_breadcrumbs
<?php
function dimox_breadcrumbs() {
/* === OPTIONS === */
$text['home'] = 'Home'; // text for the 'Home' link
$text['category'] = 'Archive by Category "%s"'; // text for a category page
$text['search'] = 'Search Results for "%s" Query'; // text for a search results page
$text['tag'] = 'Posts Tagged "%s"'; // text for a tag page
$text['author'] = 'Articles Posted by %s'; // text for an author page
You can’t perform that action at this time.