Glide is the easiest way to create useful slide for all of your Gists.
- input key
<-
to go backward. - input key
->
to go forward.
<?php | |
require_once 'Diggin/Scraper.php'; | |
function docomo_device($value) | |
{ | |
$value = mb_ereg_replace('\n', '', (string)$value); | |
$value = str_replace(' ', '', $value); | |
preg_match('/([^(]+)(((.*)))?/iu', $value, $match); |
<?php | |
require_once 'Diggin/Scraper.php'; | |
function getDevice($value) | |
{ | |
preg_match('/([^(]+)(((.*)))?/iu', $value, $match); | |
$device = $match[1]; | |
return $device; | |
} |
#!/bin/sh | |
# create project | |
mkdir $1 | |
ethna add-project -b $1 site | |
# move directory | |
mv $1/site $1/project | |
mv $1/project/www/* $1/ | |
rm -r $1/project/www |
<?php | |
/* | |
URLによってコントローラを切り替える | |
*/ | |
require_once 'Net/URL/Mapper.php'; | |
$router = Net_URL_Mapper::getInstance(); | |
$router->connect('/:controller*params', array('controller' => 'default'), array('controller' => '[a-zA-Z_]+')); |
<?php | |
require_once 'IO/SWF/Editor.php'; | |
require_once 'IO/SWF/JPEG.php'; | |
class File_SWF | |
{ | |
const SWF_TAG_End = 0; | |
const SWF_TAG_ShowFrame = 1; |
#import <UIKit/UIKit.h> | |
@interface GestureImageView : UIImageView <UIGestureRecognizerDelegate> { | |
} | |
@end |
<?php | |
// http://codezine.jp/article/detail/1051 | |
function deleteDir($dir) | |
{ | |
$iterator = new RecursiveDirectoryIterator($dir); | |
foreach (new RecursiveIteratorIterator($iterator, RecursiveIteratorIterator::CHILD_FIRST) as $file) { | |
if ($file->isDir()) { | |
rmdir($file->getPathname()); | |
} else { |
<?php | |
class MyObject | |
{ | |
public $_aaa = 'aaa'; | |
protected $_bbb = 'bbb'; | |
private $_ccc = 'ccc'; | |
} | |
$ php -v | |
PHP 5.3.8 (cli) (built: Sep 3 2011 12:31:30) | |
Copyright (c) 1997-2011 The PHP Group | |
Zend Engine v2.3.0, Copyright (c) 1998-2011 Zend Technologies | |
with Xdebug v2.1.1, Copyright (c) 2002-2011, by Derick Rethans |