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
<div id="map_canvas" style="width:100%;height:500px;"></div> | |
<script> | |
function initMap() { | |
api = 'https://maps.googleapis.com/maps/api/geocode/json?address={address}®ion=jp&key={key}'; | |
jQuery.getJSON(api, function(r){ | |
var abc = $.parseJSON(JSON.stringify(r)); | |
var lat = abc['results'][0].geometry.location.lat; | |
var lng = abc['results'][0].geometry.location.lng; | |
var uluru = {lat: lat, lng: lng }; |
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
$arr_name_kana = array( | |
'あ' => array('あ', 'い', 'う', 'え', 'お', 'ア', 'イ', 'ウ', 'エ', 'オ'), | |
'か' => array('か', 'き', 'く', 'け', 'こ', 'カ', 'キ', 'ク', 'ケ', 'コ'), | |
'さ' => array('さ', 'し', 'す', 'せ', 'そ', 'サ', 'シ', 'ス', 'セ', 'ソ'), | |
'た' => array('た', 'ち', 'つ', 'て', 'と', 'タ', 'チ', 'ツ', 'テ', 'ト'), | |
'な' => array('な', 'に', 'ぬ', 'ね', 'の', 'ナ', 'ニ', 'ヌ', 'ネ', 'ノ'), | |
'は' => array('は', 'ひ', 'ふ', 'へ', 'ほ', 'ハ', 'ヒ', 'フ', 'ヘ', 'ホ'), | |
'ま' => array('ま', 'み', 'む', 'め', 'も', 'マ', 'ミ', 'ム', 'メ', 'モ'), | |
'や' => array('や', 'ゆ', 'よ', 'ヤ', 'ユ', 'ヨ'), | |
'ら' => array('ら', 'り', 'る', 'れ', 'ろ', 'ラ', 'リ', 'ル', 'レ', 'ロ'), |
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
/** | |
* Show column name kana | |
*/ | |
if ( ! function_exists( 'kana_cpt_columns' ) ) { | |
function kana_cpt_columns( $columns ) { | |
if ( !isset($_GET['taxonomy']) || $_GET['taxonomy'] != 'category' ) | |
return $columns; | |
$columns["namekana"] = "Name Kana"; | |
return $columns; | |
} |
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
function replace($str) { | |
if(!$str) return false; | |
$unicode = array( | |
'a'=>array('á','à','ả','ã','ạ','ă','ắ','ặ','ằ','ẳ','ẵ','â','ấ','ầ','ẩ','ẫ','ậ'), | |
'A'=>array('Á','À','Ả','Ã','Ạ','Ă','Ắ','Ặ','Ằ','Ẳ','Ẵ','Â','Ấ','Ầ','Ẩ','Ẫ','Ậ'), | |
'd'=>array('đ'), | |
'-'=>array('-'), | |
'D'=>array('Đ'), | |
'e'=>array('é','è','ẻ','ẽ','ẹ','ê','ế','ề','ể','ễ','ệ'), | |
'E'=>array('É','È','Ẻ','Ẽ','Ẹ','Ê','Ế','Ề','Ể','Ễ','Ệ'), |
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
(function($){ | |
$.fn.extend({ | |
limit: function(limit,element) { | |
var interval, f; | |
var self = $(this); | |
$(this).focus(function(){ | |
interval = window.setInterval(substring,100); | |
}); | |
$(this).blur(function(){ | |
clearInterval(interval); |
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
/** | |
* Created by ENQ on 7/15/2015. | |
*/ | |
/*---------------------------------------------------------------------------------*/ | |
/* CONFIGS */ | |
/*---------------------------------------------------------------------------------*/ | |
var maxItemAdd = 3; | |
var temp = 0; // for text | |
var tempImg = 0; //for image | |
var count_click = 0; //click |
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
::selection { background: #e2eae2; } | |
::-moz-selection { background: #e2eae2; } | |
::-webkit-selection { background: #e2eae2; } |
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
$(window).bind('load', function(){ | |
//code here | |
}) |
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
1. setup node JS laster + Python 2.7 | |
2. Add Environment Variable JAVA_HOME = C:\Program Files\Java\jdk1.8.0_111 | |
Add Environment Variable ANDROID_HOME = C:\Users\Administrator\AppData\Local\Android\sdk | |
Add Environment ADB into Parts = C:\Users\Administrator\AppData\Local\Android\sdk\platform-tools | |
3. Setup Virtual Device -> SDK ... API 23 | |
4. Creat & start Android Emulator | |
5. Create react native project | |
- npm install -g react-native-cli | |
- react-native init AwesomeProject | |
- cd AwesomeProject |