$ mysql -u root -p < /usr/local/mysql/share/innodb_memcached_config.sql
mysql> install plugin daemon_memcached soname "libmemcached.so";
$ telnet localhost 11211
<?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){ |
$ mysql -u root -p < /usr/local/mysql/share/innodb_memcached_config.sql
mysql> install plugin daemon_memcached soname "libmemcached.so";
$ telnet localhost 11211
#!/usr/bin/ruby | |
# -*- coding: utf-8 -*- | |
class FileList | |
def initialize(filelist) | |
@filelist = filelist | |
@disposedlist = nil | |
end | |
def disposeList() |
$ ls -l /opt/local/apache2/conf
bar.example.com.conf
foo.example.com.conf
httpd.conf@ -> bar.example.com.conf
$ sudo a2ensite foo.example.com
$ls -l /opt/local/apache2/conf
bar.example.com.conf
foo.example.com.conf
<?php | |
//SETTINGS | |
//Facebook APP ID | |
$client_id = 'YOUR_APP_ID'; | |
//Facebook APP SECRET | |
$client_secret = 'YOUR_APP_SECRET'; | |
//WebURI to access this script | |
$redirect_uri = 'http://YOUR.DOMAIN/PATH/TO/this_script.php'; | |
//Scopes U need | |
//Scopes: https://developers.facebook.com/docs/authentication/permissions/ |