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 | |
App::import('Vendor', 'Oauth', array('file' => 'OAuth'.DS.'OAuthClient.php')); | |
class TwitterApiComponent extends Component { | |
/** | |
* 使用するコンポーネント | |
*/ | |
public $components = array('Session'); |
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
cd C:\Program Files\WinSCP | |
winscp.exe /console /script=C:\Users\***\winscp_fileup.txt | |
del C:\Users\***\images\*.jpg |
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
<IfModule mod_rewrite.c> | |
RewriteEngine On | |
RewriteBase /***/ | |
RewriteCond %{SERVER_PORT} !^443$ | |
RewriteCond %{REQUEST_URI} !^(.*\.(jpg|gif|png|jpeg|js|css))$ [NC] | |
RewriteRule ^(.*)?$ https://%{HTTP_HOST}/***/$1 [L,R] | |
RewriteCond %{REQUEST_FILENAME} !-d | |
RewriteCond %{REQUEST_FILENAME} !-f |
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
ErrorDocument 404 /****/notfound/index.html | |
RewriteEngine On | |
RewriteCond %{HTTP_USER_AGENT} Android.*Mobile | |
RewriteCond %{REQUEST_URI} !^/.*\.(gif|jpg)$ | |
RewriteCond %{REQUEST_URI} !/sp/.*$ | |
RewriteCond %{REQUEST_URI} !/notfound/.*$ | |
RewriteRule ^(.*)$ /****/sp/$1 [R,L] |
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 | |
class ImportcsvShell extends AppShell | |
{ | |
var $uses = array('Serials'); | |
function main(){} | |
function index(){ | |
$arg0 = $this -> args[0]; //コマンドで渡した引数の受取 |
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 | |
// <a> </a> タグ以外をhtmlspecialcharsする関数 | |
function atagigaiwohsc($src,$flags = ENT_QUOTES){ | |
// encode including <a></a> | |
$sanitized = htmlspecialchars($src,$flags); | |
// decode all <a> | |
if(preg_match_all('@<a.*?>@', $sanitized, $matches, PREG_SET_ORDER)){ | |
foreach($matches as $match){ |