This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Ogp Helper class file | |
* | |
* Adds OGP elements in <head /> | |
* | |
* Licensed under The MIT License | |
* | |
* @author Masunaga Ray (http://www.msng.info/) | |
* @link http://www.msng.info/archives/2011/12/cakephp-ogp-helper.php |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/app/tmp/cache/* | |
!/app/tmp/cache/models/ | |
!/app/tmp/cache/persistent/ | |
!/app/tmp/cache/views/ | |
/app/tmp/cache/models/* | |
!/app/tmp/cache/models/empty | |
/app/tmp/cache/persistent/* | |
!/app/tmp/cache/persistent/empty |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
array( | |
"New Year's Day" => '元日', | |
"Coming-of-Age Day" => '成人の日', | |
"National Foundation Day" => '建国記念の日', | |
"Vernal Equinox Day" => '春分の日', | |
"Showa Day" => '昭和の日', | |
"Constitution Memorial Day" => '憲法記念日', | |
"Greenery Day" => 'みどりの日', | |
"Children's Day" => 'こどもの日', | |
"Marine Day" => '海の日', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[alias] | |
delete-merged-branches = !git branch --merged master | grep -v -e \\* -e master -e develop | xargs git branch -d | |
delete-merged-remote-branches = !git fetch --all --prune && git branch -r --merged master | grep -v -e master -e develop | sed -e 's%/% %' | xargs -n 2 git push --delete |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function number_unformat($number, $force_number = true, $dec_point = '.', $thousands_sep = ',') { | |
if ($force_number) { | |
$number = preg_replace('/^[^\d]+/', '', $number); | |
} else if (preg_match('/^[^\d]+/', $number)) { | |
return false; | |
} | |
$type = (strpos($number, $dec_point) === false) ? 'int' : 'float'; | |
$number = str_replace(array($dec_point, $thousands_sep), array('.', ''), $number); | |
settype($number, $type); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function strpos_array($haystack, $needles, $offset = 0) { | |
if (is_array($needles)) { | |
foreach ($needles as $needle) { | |
$pos = strpos_array($haystack, $needle); | |
if ($pos !== false) { | |
return $pos; | |
} | |
} | |
return false; |
OlderNewer