Skip to content

Instantly share code, notes, and snippets.

@nveid
nveid / class2go.wsgi
Created October 10, 2012 02:10
class2go.wsgi
import os, sys
import site
# Remember original sys.path.
prev_sys_path = list(sys.path)
# we add currently directory to path and change to it
pwd = os.path.dirname(os.path.abspath(__file__))
os.chdir(pwd)
sys.path = [pwd] + sys.path
@nveid
nveid / ShortHash.php
Created October 17, 2012 21:48
ShortHex Hash generator
<?php
/**
* Copyright 2012 Silvona Services. All Rights Reserved.
* File Created By: Rick L Bird
* Created TimeStamp: 9/29/12 2:39 AM
*/
namespace Silvona\Core\AppBundle\Utils;
/* KevinBurnsJr Blog - PHP Unique Hash.
* Using a variation proposed by Ernesto on December 19th, 2011 using the PHP BC Math Library