var _save_key = "freeBending20180331"; var _o; var _lang = getLang(); if(false){ _lang = ""; } function getLang(){ _lang = (window.navigator.languages && window.navigator.languages[0]) || window.navigator.language || window.navigator.userLanguage || window.navigator.browserLanguage;//ja-JP//en-US", "zh-CN"// " en "、" ja "、 " fr "、" es-ES " _lang = _lang.substr(0,2); if(_lang == "ja"){ _lang = ""; } return _lang; } function execCopy(string){ var temp = document.createElement('div'); temp.appendChild(document.createElement('pre')).textContent = string; var s = temp.style; s.position = 'fixed'; s.left = '-100%'; document.body.appendChild(temp); document.getSelection().selectAllChildren(temp); var result = document.execCommand('copy'); document.body.removeChild(temp); // true なら実行できている falseなら失敗か対応していないか return result; } function copyClickBoard(tagName, nonTxtInfo="", copyTxt="", okTxt=""){ if(!copyTxt){ copyTxt = document.getElementById(tagName).value; } if(!copyTxt){ if(Array.isArray(nonTxtInfo)){ nonTxtInfo = nonTxtInfo[_lang=="en"?1:0]; } alert(nonTxtInfo ? nonTxtInfo : (_lang=="en"?"There is no character to be copied.":'コピーする文字がありません。')); }else if(execCopy(copyTxt)){ alert(okTxt?okTxt:_lang=="en"?"Copied!":'コピーしました!'); }else{ alert(_lang=="en"? 'This browser does not support the copy button. Sorry to trouble you, but please copy and paste manually.': 'このブラウザはコピーボタンに対応していません。お手数ですが手動でコピペしてください。'); } } function setRedirectLink(url,isBlank){ if(true&&isBlank){ window.open(url, '_blank', 'width=600, height=500, menubar=no, toolbar=no, scrollbars=yes'); }else{ location.href = url; } } function generateUID(len){ var s = ""; var a = ["a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z", "A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z", "0","1","2","3","4","5","6","7","8","9"]; for(var i=0; i