Skip to content

Instantly share code, notes, and snippets.

View koyhoge's full-sized avatar

KOYAMA Tetsuji koyhoge

View GitHub Profile
@koyhoge
koyhoge / single_execution.php
Created December 8, 2011 12:54
single_exection patched by koyhoge
<?php
/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
// created by bto
// via http://blog.bz2.jp/archives/2008/05/1php.html
// http://blog.bz2.jp/archives/2008/05/singleexecution.html
class singleExecution
{
var $key = null;
var $options = array(
<?php
// $Id$
if (!function_exists('array_val')) {
function array_val(&$data, $key, $default = null) {
if (!is_array($data)) {
return $default;
}
return isset($data[$key])? $data[$key]: $default;
}