 |
 |
|
|
パソコンからのアクセスを制限し携帯電話からの閲覧のみ許可したい場合は、
.htaccessを設置しアクセスを許可するIPアドレスもしくはホスト名を記述
する方法が一般的です。
 |
|
1, FFFTPをダウンロードしインストールをします。
 |
|
2, 「記載例」をコピー&ペーストし、.htaccessというファイル名で保存します。 |
|
.htaccessの記載例
order deny,allow
deny from all
# iモード端末からのみを許可する
allow from 210.153.84.0/24
allow from 210.136.161.0/24
# EZweb端末からのみを許可する
allow from 210.169.40.0/24
allow from 210.196.3.192/26
allow from 210.196.5.192/26
allow from 210.230.128.0/24
allow from 210.230.141.192/26
allow from 210.234.105.32/29
allow from 210.234.108.64/26
allow from 210.251.1.192/26
allow from 210.251.2.0/27
allow from 211.5.2.128/25
allow from 211.5.7.0/24
allow from 218.222.1.0/24
allow from 61.117.0.0/24
allow from 61.117.1.0/24
allow from 61.117.2.0/26
allow from 61.202.3.0/24
allow from 219.108.158.0/26
allow from 219.125.148.0/24
allow from 222.5.63.0/24
allow from 222.7.56.0/24
 |
|
3. 作成後、アクセスを拒否したいディレクトリに.htaccessをアップロードします。 |
|
設置は、以下の例を参考にしてください。
[public_html](HP公開エリア)
┣index.html(携帯でもPC可)
┗[mobile](携帯専用)
┣.htaccess
┣index.html
┗[sub1](サブフォルダ)
┣index.html
┗[image](画像など)
携帯キャリアのIPアドレスは、適宜増設されています。
各キャリアページで随時確認し常に最新のIPアドレスを追加して下さい。
|
|
 |
|
  |
|
 |
|