Open ruiishiguro opened 2 years ago
1時間調べてみてください。
@Sayuri-Y これでOSの条件判定が出来るかも。
@ruiishiguro
ありがとうございます! 送っていただいたリンクを参考にやってみますー!
@ruiishiguro
apple の時には 英語サイト、それ以外は日本語サイトに飛ぶように現状設定してみました。 apple 以外のデバイスで確認できてないのでアレですが、多分大丈夫なはず。。。!
@Sayuri-Y ありがとうございます。 こちら実機で確認してご連絡差し上げますー。
リンク先をクライアントに確認する
@ruiishiguro
共有しておらずすみません。。。! index.js の下記の部分がリンク出しわけの記述になっております! よろしくお願いいたします!
var link = function link() {
var ua = window.navigator.userAgent.toLowerCase();
var target = document.getElementById('device');
if (ua.indexOf('iphone') !== -1) {
target.href = 'https://www.placy.city/en/';
} else if (ua.indexOf('ipad') !== -1 || ua.indexOf('macintosh') !== -1) {
target.href = 'https://www.placy.city/en/';
} else if (ua.indexOf('mac os x') !== -1) {
target.href = 'https://www.placy.city/en/';
} else {
target.href = 'https://www.placy.city/ja/';
}
var ua2 = window.navigator.userAgent.toLowerCase();
var target2 = document.getElementById('device2');
if (ua.indexOf('iphone') !== -1) {
target2.href = 'https://www.placy.city/en/';
} else if (ua2.indexOf('ipad') !== -1 || ua.indexOf('macintosh') !== -1) {
target2.href = 'https://www.placy.city/en/';
} else if (ua2.indexOf('mac os x') !== -1) {
target2.href = 'https://www.placy.city/en/';
} else {
target2.href = 'https://www.placy.city/ja/';
}
};
appleかそれ以外かでリンク先を変更出来るか検証 出来なければダウンロード先の選択をモーダルで表示させます。