携帯サイトの変更点

-*参考URL
-**全般
+!!!参考URL
+!!全般
+
+!!!サンプルコード
+!!簡単認証(Perl)
+::以下より抜粋
+:::http://www.rescue.ne.jp/cgi/keitai_login/
+
+ $UA = $ENV{'HTTP_USER_AGENT'};
+ $SN = $ENV{'HTTP_X_UP_SUBNO'}; # サブスクライバID(ezWEB)
+ 
+ if (($UA =~ 'UP.B') && ($SN ne "")) {
+ 
+     $ua = "ezweb";
+     if ($ENV{'HTTP_X_UP_DEVCAP_MULTIMEDIA'}) { $ua = "ezweb2"; } # WAP2.0対応機種
+ 
+     $UID = $SN;
+ }
+ elsif ($UA =~ /^DoCoMo\/\d/) {
+ 
+     $ua = "imode";
+ 
+     if ($UA =~ /ser(\w{15})/) { $UID = $1; } # <foma> DoCoMo/2.0 N2001(c10;serXXXXXXXXXXXXXXX; iccxxxxxxxxxxxxxxxxxxxx)
+     elsif ($UA =~ /ser(\w{11})/) { $UID = $1; } # <mova> DoCoMo/1.0/X503i/c10/serNMAIA000001
+ }
+ elsif ($UA =~ /^J-PHONE\/\d/) {
+ 
+     $ua = "j-sky";
+ 
+     if ($UA =~ /.*\/.*\/.*\/SN(\w+)\s/) { $UID = $1; } # パケット対応機 J-PHONE/4.0/J-SH51/SN************ SH/0001a Profile/MIDP-1.0 Configuration/CLDC-1.0 Ext-Profile/JSCL-1.1.0
+ }
+ else { $ua = 0; }
+ 
+ if (!$ua || $UID eq "") { &error("エラー","あなたの端末では識別情報が取得できないため簡単ログインが利用できません"); }
+
トップ 一覧 検索 RSS ログイン