This file contains hidden or 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
"---------------------------------------------------- | |
" showmarks.vim | |
" <Leader>mt ON/OFFトグル。 | |
" <Leader>mm 次の使えるマークを使ってマーク。 | |
" <Leader>mh カレント行ののマークを削除。 | |
" <Leader>ma カレントバッファのマークを全部削除。 | |
"---------------------------------------------------- | |
" Enable ShowMarks | |
let showmarks_enable = 1 | |
" Show which marks |
This file contains hidden or 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 | |
$c = 'a'; | |
echo ++$c; | |
echo chr(ord($c)+1); |
This file contains hidden or 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 | |
// View | |
$flags = array( | |
pow(2,0) => 'フラグ1', | |
pow(2,1) => 'フラグ2', | |
pow(2,2) => 'フラグ3', | |
pow(2,3) => 'フラグ4', | |
); | |
$checked = array(); |
This file contains hidden or 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
// ビュー | |
<?= $form->create(array('action' => 'upload', 'type' => 'file')) ?> | |
<?= $form->input('UI.file', array('type' => 'file')) ?> | |
<?= $form->submit('アップロード') ?> | |
<?= $form->end() ?> | |
<?php | |
// コントローラ | |
App::import('Vendor', 'Stream_Filter_Mbstring', array('file' => 'openpear/Stream/Filter/Mbstring.php')); |
This file contains hidden or 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
{ | |
"build_path": { | |
"models": [ | |
"/full/path/to/models/", | |
"/next/full/path/to/models/" | |
], | |
"components": [ | |
"/full/path/to/components/", | |
"/next/full/path/to/components/" | |
], |
This file contains hidden or 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
<?= $form->create() ?> | |
<?= preg_replace_callback( | |
'/\{(?<type>text|checkbox):(?<name>[^\|}]+){1}(?:(?:\|validate:(?<validate>[\w,]+))?(?:\|class:(?<class>[\w,]+))?)*\}/' | |
function ($match) use ($form) { | |
$option = array('type' => $match['type']); | |
if (isset($match['validate'])) { | |
// validation | |
} |
This file contains hidden or 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
" srcexpl.vim {{{ | |
NeoBundle 'Source-Explorer-srcexpl.vim' | |
" リフレッシュタイム(ms) | |
let g:SrcExpl_RefreshTime = 1000 | |
let g:SrcExpl_winHeight = 8 | |
let g:SrcExpl_searchLocalDef = 1 | |
" srcexpl起動次に自動でtagsを作るかどうか |
This file contains hidden or 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
" ctrlp.vim {{{ | |
NeoBundle 'kien/ctrlp.vim' | |
let g:ctrlp_by_filename = 1 " フルパスではなくファイル名のみで絞込み | |
let g:ctrlp_jump_to_buffer = 2 " タブで開かれていた場合はそのタブに切り替える | |
let g:ctrlp_clear_cache_on_exit = 0 " 終了時キャッシュをクリアしない | |
let g:ctrlp_mruf_max = 500 " MRUの最大記録数 | |
" let g:ctrlp_highlight_match = [1, 'IncSearch'] " 絞り込みで一致した部分のハイライト | |
let g:ctrlp_open_new_file = 1 " 新規ファイル作成時にタブで開く | |
let g:ctrlp_open_multi = '10t' " 複数ファイルを開く時にタブで最大10まで開く |
This file contains hidden or 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
<!DOCTYPE HTML> | |
<html lang="ja"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>yieldのテスト</title> | |
<script src="https://www.google.com/jsapi" type="text/javascript"></script> | |
<script> | |
google.load("jquery", "1.7"); | |
</script> | |
<script type="text/javascript; version=1.7"> |
This file contains hidden or 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
// 社外からはBASIC認証 | |
if (Configure::read('debug') == 0 && !$this->_inOfficeNetwork()) { | |
$this->Security->loginOptions = array('type' => 'Basic'); | |
$this->Security->loginUsers = Configure::read('BasicAuthentication'); | |
$this->Security->requireLogin('*'); | |
} |