diff -Nur webalizer-1.30-04/Makefile.in webalizer-1.30-04-jp/Makefile.in --- webalizer-1.30-04/Makefile.in Tue Jun 29 14:12:40 1999 +++ webalizer-1.30-04-jp/Makefile.in Sun Dec 12 04:35:42 1999 @@ -33,22 +33,29 @@ # where are the GD header files? GDLIB = @GDLIB@ +# Japanese +CFLAGS+= -I./ +LIBS+= -L/usr/local/lib -lttf -lpng -lz + # Shouldn't have to touch below here! all: webalizer -webalizer: webalizer.o webalizer.h graphs.o graphs.h ctry.h webalizer_lang.h - $(CC) ${LDFLAGS} -o webalizer webalizer.o graphs.o ${LIBS} +webalizer: webalizer.o webalizer.h graphs.o gd15j.o graphs.h ctry.h webalizer_lang.h + $(CC) ${LDFLAGS} -o webalizer webalizer.o graphs.o gd15j.o ${LIBS} webalizer.o: webalizer.c webalizer.h webalizer_lang.h ctry.h $(CC) ${CFLAGS} ${DEFS} -c webalizer.c -graphs.o: graphs.c graphs.h webalizer_lang.h +graphs.o: graphs.c graphs.h webalizer_lang.h gd15j.c gd15j.h $(CC) ${CFLAGS} ${DEFS} -I${GDLIB} -c graphs.c +gd15j.o: gd15j.c gd15j.h + $(CC) ${CLAGS} ${DEFS} -I${GDLIB} -c gd15j.c + clean: rm -f webalizer *.o usage*.gif daily*.gif hourly*.gif ctry*.gif - rm -f *.html *.hist *.current core + rm -f *~ *.html *.hist *.current core distclean: clean rm -f webalizer.conf *.tar *.tgz *.Z diff -Nur webalizer-1.30-04/README.jp webalizer-1.30-04-jp/README.jp --- webalizer-1.30-04/README.jp Thu Jan 1 09:00:00 1970 +++ webalizer-1.30-04-jp/README.jp Sun Dec 12 04:24:59 1999 @@ -0,0 +1,26 @@ +Webalizer Japanese Patch + Yasuyuki Furukawa, 1999 + Keio University in japan. + +REQUIRE: + Japanese gd library with VFlib. + +COMPILE: + % ln -sf lang/webalizer_lang.japanese webalizer_lang.h + % make + + +NOTE: + This patch, in default, output progress messages + in Japanese-EUC encoding. If you use webalizer as cron + process, you must use nkf(Network Kanji Filter) to recode + log messages into JIS encoding. + + ex) + % webalizer | nkf -j + + If you not need Japanese log messages, please define + in webalizer_lang.japanese: + + #undef MINI_JP + diff -Nur webalizer-1.30-04/README.jp.1-30-04 webalizer-1.30-04-jp/README.jp.1-30-04 --- webalizer-1.30-04/README.jp.1-30-04 Thu Jan 1 09:00:00 1970 +++ webalizer-1.30-04-jp/README.jp.1-30-04 Sun Dec 12 06:05:16 1999 @@ -0,0 +1,65 @@ +Wed Dec 8 14:01:14 JST 1999 + +webalizer-1.30-04-jp.patch + +yasu@on.cs.keio.ac.jp $B$5$s$K$h$k(B webalizer-1-22-01 $B$X$NF|K\8l%Q%C%A$r(B +$B85$K!"(B1999.12.8 $B8=:_$N:G?7$G$"$k(B webalizer-1-30-04 $B$KBP1~$5$;$?$b$N!#(B +$B$D$$$G$K(B GD 1.6 $B0J9_$N(B PNG $B$KBP1~$5$;$?(B($B4X?tL>$r=$@5$7$?$@$1(B) +$BF|K\8l%U%)%s%H$O(B VFlib $B7PM3$G$O$J$/!"(BGD $B%i%$%V%i%j$N5!G=$r;H$C$F!"D>@\(B +TrueType $B%U%)%s%H$rFI$`!#$?$@$7!"(BgdImageString(), gdImageStringUp() $B$r(B +($B$5$\$C$F(B)$B$=$N$^$^;H$$$?$$$N$G!";32l@5?M(B @ $B@iMUBg3XAm9g>pJs=hM}%;%s%?!<(B +$B$5$s$N(B gd15j.[ch] $B$rMxMQ$7$F$$$k!#(B + +$B:n$jJ}(B +~~~~~~ +1. freetype-1.3 $B$N%3%s%Q%$%k$H%$%s%9%H!<%k(B + +2. gd-1.7.3 $B$N%3%s%Q%$%k(B + + * CFLAGS $B$K(B -DHAVE_LIBTTF $B$rDI2C$9$k(B + * Solaris 2.* $B$K4^$^$l$k(B TrurType $B%U%)%s%H$r;H$&>l9g$O(B CFLAGS + $B$K(B -DJISX0208 $B$rDI2C$9$k(B + * Microsoft $B$N(B msgochic.(ttc|ttf) $B$r;H$&>l9g$O(B CFLAGS $B$K(B + -DJISX0208 $B$rDI2C$9$k(B + * LIBS $B$K(B -lttf $B$rDI2C$9$k(B + +3. webalizer $B$N%3%s%Q%$%k$H%$%s%9%H!<%k(B + + gd15j.c $B$N(B DEFFONT $B$K(B TrueType $B%U%)%s%H$N%Q%9$r;XDj$9$k!#(B + + % ./configure --with-gdlib=(GD $B$N%Q%9(B) --with-gd=(GD $B$N%Q%9(B) + + Makefile $B$N(B LIBS+= $B$rD4@0$7(Bttf $B$H(B png $B$r;XDj$9$k!#(B + + % make + # make install + + +$B$*$^$1$N%j%s%/=8(B +~~~~~~~~~~~~~~~~ + + webalizer $BG[I[85(B + http://www.mrunix.net/webalizer/ + + GD $B%i%$%V%i%j(B + http://www.boutell.com/gd/ + + libpng + http://www.cdrom.com/pub/png/ + + zlib + http://www.cdrom.com/pub/infozip/zlib/ + + VFlib + http://TypeHack.aial.hiroshima-u.ac.jp/VFlib/ + + FreeType + ftp://ftp.freetype.org/pub/freetype/ + + webalizer $B$NF|K\8l%Q%C%A(B + http://www.on.cs.keio.ac.jp/~yasu/linux/webalizer/ + + GD $B%i%$%V%i%j$NF|K\8l%Q%C%A(B + ftp://ftp.ipc.chiba-u.ac.jp/pub/pub.yamaga/gd/ + +-- gotoh@hinet.co.jp diff -Nur webalizer-1.30-04/configure webalizer-1.30-04-jp/configure --- webalizer-1.30-04/configure Tue Jun 29 14:17:44 1999 +++ webalizer-1.30-04-jp/configure Sun Dec 12 04:30:13 1999 @@ -16,7 +16,7 @@ ac_help="$ac_help --with-gd=DIR Where to additionally look for gd headers" ac_help="$ac_help ---with-language=language Use 'language' (default is english)" +--with-language=language Use 'language' (default is japanese)" # Initialize some variables set by options. # The variables have the same names as the options, with @@ -525,7 +525,7 @@ -DEFAULT_LANG="english" +DEFAULT_LANG="japanese" # Extract the first word of "gcc", so it can be a program name with args. diff -Nur webalizer-1.30-04/gd15j.c webalizer-1.30-04-jp/gd15j.c --- webalizer-1.30-04/gd15j.c Thu Jan 1 09:00:00 1970 +++ webalizer-1.30-04-jp/gd15j.c Sun Dec 12 06:02:27 1999 @@ -0,0 +1,64 @@ +/****************************************************************************/ +/* gd1.5j comatible wrapper program */ +/* */ +/* Information Processing Center, Chiba University */ +/* Masahito Yamaga */ +/* */ +/* Usage: */ +/* modify DEFFONT in gd15j.c and compile it. */ +/* */ +/* gcc -c -g -O2 gd15j.c */ +/* */ +/* modify source codes of applications using gd1.5j like: */ +/* */ +/* #include "gd.h" ----> #include "gd15j.h" */ +/* */ +/* compile and link them with gd15j.o like: */ +/* */ +/* gcc -c -g -O2 [source] */ +/* gcc -o [program] [objs].... gd15j.o -lgd -lttf -lpng -lz -lm */ +/* */ +/****************************************************************************/ + +#include "gd.h" + +/* +#define DEFFONT "/usr/local/share/fonts/truetype/msgothic.ttc" +*/ +#define DEFFONT "/usr/openwin/lib/locale/ja/X11/fonts/TT/HG-MinchoL.ttf" + +void _gdImageString(gdImagePtr im, gdFontPtr f, + int x, int y, unsigned char *s, int color) +{ + static int brect[8]; + char *err; + int offset; + double sz = ((f->h)+(f->w))/2.; + + err = gdImageStringTTF((gdImagePtr)NULL,&brect[0],0, + DEFFONT,sz,0,0,0,s); + if (err) {fprintf(stderr,err); return;} + + offset = abs(brect[5]-brect[1]); + gdImageStringTTF(im,&brect[0],color,DEFFONT,sz,0,x,y+offset,s); +} + +#define PI 3.141592 +#define DEG2RAD(x) ((x)*PI/180.) + +void _gdImageStringUp(gdImagePtr im, gdFontPtr f, + int x, int y, unsigned char *s, int color) +{ + static int brect[8]; + char *err; + int offset; + double sz = ((f->h)+(f->w))/2.; + double angle = DEG2RAD(90.0); + + err = gdImageStringTTF((gdImagePtr)NULL,&brect[0],0, + DEFFONT,sz,angle,0,0,s); + if (err) {fprintf(stderr,err); return;} + + offset = abs(brect[4]-brect[0]); + gdImageStringTTF(im,&brect[0],color,DEFFONT,sz,angle,x+offset,y,s); +} diff -Nur webalizer-1.30-04/gd15j.h webalizer-1.30-04-jp/gd15j.h --- webalizer-1.30-04/gd15j.h Thu Jan 1 09:00:00 1970 +++ webalizer-1.30-04-jp/gd15j.h Sun Dec 12 04:24:59 1999 @@ -0,0 +1,33 @@ +/****************************************************************************/ +/* gd1.5j comatible wrapper program */ +/* */ +/* Information Processing Center, Chiba University */ +/* Masahito Yamaga */ +/* */ +/* Usage: */ +/* modify DEFFONT in gd15j.c and compile it. */ +/* */ +/* gcc -c -g -O2 gd15j.c */ +/* */ +/* modify source codes of applications using gd1.5j like: */ +/* */ +/* #include "gd.h" ----> #include "gd15j.h" */ +/* */ +/* compile and link them with gd15j.o like: */ +/* */ +/* gcc -c -g -O2 [source] */ +/* gcc -o [program] [objs].... gd15j.o -lgd -lttf -lpng -lz -lm */ +/* */ +/****************************************************************************/ + +#ifndef GD15J_H +#define GD15J_H 1 + +#define gdImageString(im,f,x,y,s,c) _gdImageString(im,f,x,y,s,c) +#define gdImageStringUp(im,f,x,y,s,c) _gdImageStringUp(im,f,x,y,s,c) +#define gdImageGif(im,out) gdImagePng(im,out) +#define gdSetKanjiFont(x) + +#include "gd.h" + +#endif /* GD15J_H */ diff -Nur webalizer-1.30-04/graphs.c webalizer-1.30-04-jp/graphs.c --- webalizer-1.30-04/graphs.c Tue Jun 15 13:33:40 1999 +++ webalizer-1.30-04-jp/graphs.c Sun Dec 12 04:24:59 1999 @@ -30,7 +30,7 @@ #include #include #include -#include +#include #include #include #include diff -Nur webalizer-1.30-04/lang/webalizer_lang.japanese webalizer-1.30-04-jp/lang/webalizer_lang.japanese --- webalizer-1.30-04/lang/webalizer_lang.japanese Thu Jan 1 09:00:00 1970 +++ webalizer-1.30-04-jp/lang/webalizer_lang.japanese Sun Dec 12 04:24:59 1999 @@ -0,0 +1,634 @@ +/* + webalizer_lang.japanese + + Webalizer V1.2x Language Support file for Japanese. + 01-JUL-1998 by Yasuyuki Furukawa (yasu@on.cs.keio.ac.jp) + 01-Feb-1999 Modified for level 1.2 support (yasu@on.cs.keio.ac.jp) + 24-Mar-1999 Updated HTTP 1.1 response codes by (yasu@on.cs.keio.ac.jp) + + + Language files are named using the following convention: + + webalizer_lang.LANGUAGE + + where 'LANGUAGE' is the name of the language the file is + translated into (ie: webalizer_lang.russian for russian). + Either copy the desired language file to webalizer_lang.h + or create a symbolic link, then re-compile. + + If you translate this file into a different language, please + send a copy to brad@mrunix.net. + +*/ +/***********************************************************************/ +/* DEFINE LANGUAGE NAME here */ +/***********************************************************************/ +#define JAPANESE +#undef MINI_JP +char *language = "Japanese(EUC)"; + +/***********************************************************************/ +/* */ +/* Informational messages */ +/* */ +/* These messages are only displayed while The Webalizer is being run, */ +/* usually to the screen, and are not part of the HTML output. */ +/* */ +/***********************************************************************/ + +/* these are only used in timing totals */ +/* Format: XXX records (XXX ignored, XXX bad) in X.XX seconds */ +#ifdef MINI_JP +char *msg_records = "records"; +char *msg_ignored = "ignored"; +char *msg_bad = "bad"; +char *msg_in = "in"; +char *msg_seconds = "seconds"; +#else /* !MINI_JP */ +char *msg_records = "レコードありました. "; +char *msg_ignored = "行が無効"; +char *msg_bad = "行が不正"; +char *msg_in = "処理時間:"; +char *msg_seconds = "秒"; +#endif /* !MINI_JP */ + +/* progress and setup error messages */ +#ifdef MINI_JP +char *msg_log_err = "Error: Can't open log file"; +char *msg_log_use = "Using logfile"; +char *msg_dir_err = "Error: Can't change directory to"; +char *msg_dir_use = "Creating output in"; +char *msg_cur_dir = "current directory"; +char *msg_hostname= "Hostname for reports is"; +char *msg_ign_hist= "Ignoring previous history..."; +char *msg_no_hist = "History file not found..."; +char *msg_get_hist= "Reading history file..."; +char *msg_put_hist= "Saving history information..."; +char *msg_hist_err= "Error: Unable to write history file"; +char *msg_bad_hist= "Error: Ignoring invalid history record"; +char *msg_bad_conf= "Error: Unable to open configuration file"; +char *msg_bad_key = "Warning: Invalid keyword"; +char *msg_bad_date= "Error: Skipping record (bad date)"; +char *msg_ign_nscp= "Skipping Netscape header record"; +char *msg_bad_rec = "Skipping bad record"; +char *msg_no_vrec = "No valid records found!"; +char *msg_gen_rpt = "Generating report for"; +char *msg_gen_sum = "Generating summary report"; +#else /* !MINI_JP */ +char *msg_log_err = "エラー: ログファイルをオープンできません"; +char *msg_log_use = "ログファイル ― "; +char *msg_dir_err = "エラー: ディレクトリを変更できません: "; +char *msg_dir_use = "作成ディレクトリ:"; +char *msg_cur_dir = "カレントディレクトリ"; +char *msg_hostname= "報告ホスト名 ― "; +char *msg_ign_hist= "以前のヒストリを無効にします..."; +char *msg_no_hist = "ヒストリファイルが見つかりません..."; +char *msg_get_hist= "ヒストリファイルの読み込み..."; +char *msg_put_hist= "ヒストリ情報の保存..."; +char *msg_hist_err= "エラー: ヒストリファイルを書き込めません"; +char *msg_bad_hist= "エラー: 有効なヒストリレコードを無視します"; +char *msg_bad_conf= "エラー: 設定ファイルが開けません"; +char *msg_bad_key = "警告: キーワードが間違っています"; +char *msg_bad_date= "エラー: レコードをスキップしました (不正な日付)"; +char *msg_ign_nscp= "ネットスケープヘッダレコードをスキップします"; +char *msg_bad_rec = "不正レコードをスキップします"; +char *msg_no_vrec = "有効なレコードが見つかりません!"; +char *msg_gen_rpt = "月毎レポート作成 ― "; +char *msg_gen_sum = "総合レポートの作成"; +#endif /* !MINI_JP */ + +/* New for 1.1 */ /* Current state data messages */ +#ifdef MINI_JP +char *msg_get_data= "Reading previous run data..."; +char *msg_put_data= "Saving current run data..."; +char *msg_no_data = "Previous run data not found..."; +char *msg_bad_data= "Error: Unable to restore run data"; +char *msg_data_err= "Error: Unable to save current run data"; +char *msg_dup_data= "Warning: Possible duplicate data found"; +#else /* !MINI_JP */ +char *msg_get_data= "以前の実行データを読み込んでいます..."; +char *msg_put_data= "現在の実行データを保存しています..."; +char *msg_no_data = "以前の実行データが見つかりません..."; +char *msg_bad_data= "エラー: 実行データを修復できません"; +char *msg_data_err= "エラー: 現在の実行データを保存できません"; +char *msg_dup_data= "警告: 同一データが複数見つかりました"; +#endif /* !MINI_JP */ + +/* memory allocation errors */ +#ifdef MINI_JP +char *msg_nomem_ts= "Can't allocate enough memory, Top Sites disabled!"; +char *msg_nomem_tr= "Can't allocate enough memory, Top Referrers disabled!"; +char *msg_nomem_tu= "Can't allocate enough memory, Top URLs disabled!"; +char *msg_nomem_tc= "Can't allocate enough memory, Top Countries disabled!"; +char *msg_nomem_ta= "Can't allocate enough memory, Top User Agents disabled!"; +char *msg_nomem_tsr="Can't allocate enough memory, Top Search Strings disabled!"; +char *msg_nomem_dh= "Error adding host node (daily), skipping"; +char *msg_nomem_mh= "Error adding host node (monthly), skipping"; +char *msg_nomem_u = "Error adding URL node, skipping"; +char *msg_nomem_a = "Error adding User Agent node, skipping"; +char *msg_nomem_r = "Error adding Referrer node, skipping"; +char *msg_nomem_sc= "Error adding Search String Node, skipping"; +#else /* !MINI_JP */ +char *msg_nomem_ts= "メモリ確保できません, 上位サイト表は作成しません!"; +char *msg_nomem_tr= "メモリ確保できません, 上位リンク元の表は作成しません!"; +char *msg_nomem_tu= "メモリ確保できません, 上位URL表は作成しません!"; +char *msg_nomem_tc= "メモリ確保できません, 上位国の表は作成しません!"; +char *msg_nomem_ta= "メモリ確保できません, 上位ブラウザ表は作成しません!"; +char *msg_nomem_tsr="メモリ確保出来ません, 上位検索文字列表は作成しません!"; +char *msg_nomem_dh= "ホストノード(毎日)追加のエラー, スキップします"; +char *msg_nomem_mh= "ホストノード(毎月)追加のエラー, スキップします"; +char *msg_nomem_u = "URLノード追加のエラー, スキップします"; +char *msg_nomem_a = "使用ブラウザノード追加のエラー, スキップします"; +char *msg_nomem_r = "リンク元ノード追加のエラー, スキップします"; +char *msg_nomem_sc= "検索文字列ノード追加のエラー, スキップします"; +#endif /* !MINI_JP */ + +/* log record errors */ +#ifdef MINI_JP +char *msg_big_rec = "Error: Skipping oversized log record"; +char *msg_big_host= "Warning: Truncating oversized hostname"; +char *msg_big_date= "Warning: Truncating oversized date field"; +char *msg_big_req = "Warning: Truncating oversized request field"; +char *msg_big_ref = "Warning: Truncating oversized referrer field"; +char *msg_big_one = "Warning: String exceeds storage size"; +#else /* !MINI_JP */ +char *msg_big_rec = "エラー: オーバーサイズのレコードをスキップします"; +char *msg_big_host= "警告: ホスト名のオーバーサイズ分を切捨てます"; +char *msg_big_date= "警告: データ欄のオーバーサイズ分を切捨てます"; +char *msg_big_req = "警告: リクエスト欄のオーバーサイズ分を切捨てます"; +char *msg_big_ref = "警告: リンク元欄のオーバーサイズ分を切捨てます"; +char *msg_big_one = "警告: 文字列がメモリサイズを超えました"; +#endif /* !MINI_JP */ + +/* misc errors */ +#ifdef MINI_JP +char *msg_no_open = "Error: Unable to open file"; +#else /* !MINI_JP */ +char *msg_no_open = "エラー: ファイルが開けません"; +#endif /* !MINI_JP */ + +/* Help display... */ +char *h_usage1 = "使用法"; +char *h_usage2 = "[オプション] [ログファイル]"; +char *h_msg[]= { + "-h = このヘルプメッセージの表示" , + "-v -V = バージョン情報の表示" , + "-d = デバッグ補助情報の表示" , + "-F = FTP ログフォーマットを利用" , + "-f = 連続したエラーを保持" , + "-g = 時刻表示に世界標準時(GMT)を使う" , + "-i = ヒストリファイルを無効にする" , + "-p = 現在の状態を留め、追加していく" , + "-q = 経過メッセージを抑制する" , + "-Q = 全てのメッセージを抑制する" , + "-Y = 国別グラフを抑制する" , + "-G = 毎時間グラフを抑制する" , + "-H = 毎時間表を抑制する" , + "-L = グラフの色別表題を抑制する" , + "-l 数値 = グラフの背景に利用する横軸数を指定", + "-m 数値 = 訪問時のタイムアウト秒数を指定" , + "-T = タイム情報を出力する" , + "-c ファイル = 設定ファイルの指定" , + "-n ホスト = HTTPサーバホスト名の指定" , + "-o dir = 出力ディレクトリの指定" , + "-t タイトル = レポートタイトルの指定" , + "-a ブラウザ = ユーザブラウザを隠す" , + "-r リンク元 = リンク元を隠す" , + "-s サイト = リモートサイト名を隠す" , + "-u URL = URL名を隠す" , + "-x 名前 = HTML拡張子の指定" , + "-P 名前 = ページの拡張子の指定" , + "-I 名前 = インデックスエイリアス名の指定" , + "-A 数値 = 表示する上位ブラウザ数の指定" , + "-C 数値 = 表示する上位国の数の指定" , + "-R 数値 = 表示する上位リンク元の数の指定" , + "-S 数値 = 表示する上位リモートサイト数の指定", + "-U 数値 = 表示する上位URL数の指定" , + "-e 数値 = 表示する上位入口ページ数の指定" , + "-E 数値 = 表示する上位出口ページ数の指定" }; + +#define LAST_HLP_MSG (int)(sizeof(h_msg)/sizeof(char *)) + +/***********************************************************************/ +/* */ +/* HTML strings */ +/* */ +/* These strings are used as part of the HTML output generated by The */ +/* Webalizer. */ +/* */ +/***********************************************************************/ + +/* header strings */ +char *msg_hhdr_sp = "統計期間 "; +char *msg_hhdr_gt = "作成日: "; +char *msg_hhdr_date = "%Y年%m月%d日 %H時%M分 %Z"; +char *msg_hhdr_gmtdate = "%Y年%m月%d日 %H時%M分 GMT"; +char *msg_year = "年"; + +/* main index strings */ +char *msg_main_us = "アクセス統計 ― "; +char *msg_main_per= "現在から12ヵ月前まで"; +char *msg_main_sum= "月別統計"; +char *msg_main_da = "一日平均"; +char *msg_main_mt = "月間合計"; + +/* month HTML page strings */ +char *msg_hmth_du = "毎日アクセス統計グラフ ― "; +char *msg_hmth_hu = "毎時間アクセス統計グラフ ― "; + +/* table header strings */ +char *msg_h_by = "順"; /* bogus */ +char *msg_h_avg = "平均"; +char *msg_h_max = "最大"; +char *msg_h_total = "合計"; +char *msg_h_totals= "合計"; +char *msg_h_day = "日にち"; +char *msg_h_mth = " 月"; +char *msg_h_hour = "時間"; +char *msg_h_hits = "ヒット"; +char *msg_h_pages = "ページ"; +char *msg_h_visits= "訪問"; +char *msg_h_files = "ファイル"; +char *msg_h_sites = "サイト"; +char *msg_h_xfer = "キロバイト"; +char *msg_h_hname = "ホスト名"; +char *msg_h_url = "URL名"; +char *msg_h_agent = "使用ブラウザ"; +char *msg_h_ref = "リンク元URL"; +char *msg_h_ctry = "国名"; +char *msg_h_search= "検索文字列"; + +/* links along top of page */ +char *msg_hlnk_ds = "毎日統計"; +char *msg_hlnk_hs = "毎時間統計"; +char *msg_hlnk_u = "URL別統計"; +char *msg_hlnk_s = "サイト別統計"; +char *msg_hlnk_a = "ブラウザ別統計"; +char *msg_hlnk_c = "国別統計"; +char *msg_hlnk_r = "リンク元別統計"; +char *msg_hlnk_en = "入口ページ別統計"; /* bogus */ +char *msg_hlnk_ex = "出口ページ別統計"; /* bogus */ +char *msg_hlnk_sr = "検索文字列別統計"; /* bogus */ + +/* monthly total table */ +char *msg_mtot_ms = "月間集計: "; +char *msg_mtot_th = "合計ヒット数"; +char *msg_mtot_tf = "合計転送ファイル数"; +char *msg_mtot_tx = "合計転送キロバイト数"; +char *msg_mtot_us = "アクセスされたリモートサイトの分類数"; +char *msg_mtot_ur = "アクセスページへのリンク元の分類数"; +char *msg_mtot_ua = "アクセスに使用されたブラウザの種類"; +char *msg_mtot_uu = "アクセスのあったURL分類数"; +char *msg_mtot_mhd= "1日あたりのヒット数"; +char *msg_mtot_mhh= "1時間あたりのヒット数"; +char *msg_mtot_mfd= "1日あたりのファイル数"; +char *msg_mtot_mpd= "1日あたりのページ数"; +char *msg_mtot_mvd= "1日あたりの訪問数"; +char *msg_mtot_mkd= "1日あたりのキロバイト数"; +char *msg_mtot_rc = "応答コード別ヒット数"; + +/* daily total table */ +char *msg_dtot_ds = "毎日アクセス統計 ― "; + +/* hourly total table */ +char *msg_htot_hs = "毎時間アクセス統計 ― "; + +/* country pie chart */ +char *msg_ctry_use= "国別アクセス統計グラフ ― "; + +/* top tables */ +/* Formatted as "Top xxx of xxx Total something" */ +char *msg_top_top = "上位"; +char *msg_top_of = "計"; +char *msg_top_s = "のサイト中"; +char *msg_top_u = "のURL中"; +char *msg_top_r = "のリンク元中"; +char *msg_top_a = "のブラウザ中"; +char *msg_top_c = "の国中"; +char *msg_top_en = "の入口ページ中"; /* bogus */ +char *msg_top_ex = "の出口ページ中"; /* bogus */ +char *msg_top_sr = "の検索文字列中"; /* bogus */ + +/* short month names MUST BE 3 CHARS in size... pad if needed*/ +char *s_month[12]={ "1月", "2月", "3月", "4月", + "5月", "6月", "7月", "8月", + "9月", "10月", "11月", "12月"}; + +/* long month names - can be any length */ +char *l_month[12]={ "1月", "2月", "3月", "4月", + "5月", "6月", "7月", "8月", + "9月", "10月", "11月","12月"}; + +/* response code descriptions... order IS important! */ +struct response_code response[] = + { { "未定義の応答コード", 0 }, + { "Code 100 - 継続(Continue)", 0 }, + { "Code 101 - プロトコルの切り替わり", 0 }, + { "Code 200 - 正常(OK)", 0 }, + { "Code 201 - 作成(Created)", 0 }, + { "Code 202 - 受け取り(Accepted)", 0 }, + { "Code 203 - 認証情報がありません", 0 }, + { "Code 204 - 文章を含んでいません", 0 }, + { "Code 205 - コンテンツのリセット", 0 }, + { "Code 206 - 不完全なコンテンツです", 0 }, + { "Code 300 - 複数選択", 0 }, + { "Code 301 - 恒久的に移動されました", 0 }, + { "Code 301 - 見付かりました", 0 }, + { "Code 303 - 他を当たってください", 0 }, + { "Code 304 - 更新されていません", 0 }, + { "Code 305 - プロキシの使用", 0 }, + { "Code 307 - 一時的に移動されました", 0 }, + { "Code 400 - 不正リクエストです", 0 }, + { "Code 401 - 認証されませんでした", 0 }, + { "Code 402 - 支払が要求されています", 0 }, + { "Code 403 - アクセス制限されています", 0 }, + { "Code 404 - 見付かりません", 0 }, + { "Code 405 - 許可されていない手段です", 0 }, + { "Code 406 - 受け付り不可能です", 0 }, + { "Code 407 - プロキシの認証の要求", 0 }, + { "Code 408 - リクエストタイムアウト", 0 }, + { "Code 409 - 衝突(Conflict)", 0 }, + { "Code 410 - 消失(Gone)", 0 }, + { "Code 411 - 長さの要求", 0 }, + { "Code 412 - 前提条件が異なります", 0 }, + { "Code 413 - 要求内容が大きすぎます", 0 }, + { "Code 414 - リクエストURIが長すぎます", 0 }, + { "Code 415 - 未サポートのメディア形式です", 0 }, + { "Code 416 - 成功不能な要求範囲です", 0 }, + { "Code 417 - 予想に失敗しました", 0 }, + { "Code 500 - サーバー内部エラー", 0 }, + { "Code 501 - インプリメントされていません", 0 }, + { "Code 502 - ゲートウェイが正しくありません", 0 }, + { "Code 503 - サービスは利用できません", 0 }, + { "Code 504 - ゲートウェイのタイムアウト", 0 }, + { "Code 505 - 未サポートのHTTPバージョン", 0 } }; + +/* New for 1.1 */ + +char *msg_title = "アクセス統計:"; +char *msg_h_other = "その他"; + +/* Country codes (previously in ctry.h header file) */ + +struct country_code { u_long idx; + char *desc; + u_long count; + u_long files; + double xfer; + } ctry[] = { + +{ 0, "不明/未定義", 0,0,0 }, +{ IDX_3C('c','o','m'), "アメリカ コマーシャル", 0,0,0 }, +{ IDX_3C('e','d','u'), "アメリカ 教育", 0,0,0 }, +{ IDX_3C('g','o','v'), "アメリカ 政治", 0,0,0 }, +{ IDX_3C('i','n','t'), "国際 (int)", 0,0,0 }, +{ IDX_3C('m','i','l'), "アメリカ 軍事", 0,0,0 }, +{ IDX_3C('n','e','t'), "ネットワーク(net)", 0,0,0 }, +{ IDX_3C('o','r','g'), "非商業組織(org)", 0,0,0 }, +{ IDX_4C('a','r','p','a'),"旧形式Arpanet (arpa)", 0,0,0 }, +{ IDX_4C('n','a','t','o'),"NATO領域(nato)", 0,0,0 }, +{ IDX_2C('a','d'), "アンドラ公国", 0,0,0 }, +{ IDX_2C('a','e'), "アラブ首長国連邦" , 0,0,0 }, +{ IDX_2C('a','f'), "アフガニスタン", 0,0,0 }, +{ IDX_2C('a','g'), "アンティグア and Barbuda", 0,0,0 }, +{ IDX_2C('a','i'), "アンギラ", 0,0,0 }, +{ IDX_2C('a','l'), "アルバニア", 0,0,0 }, +{ IDX_2C('a','m'), "アルメニア", 0,0,0 }, +{ IDX_2C('a','n'), "オランダ Antilles", 0,0,0 }, +{ IDX_2C('a','o'), "アンゴラ", 0,0,0 }, +{ IDX_2C('a','q'), "南極大陸", 0,0,0 }, +{ IDX_2C('a','r'), "アルゼンチン", 0,0,0 }, +{ IDX_2C('a','s'), "アメリカン・サモア", 0,0,0 }, +{ IDX_2C('a','t'), "オーストリア", 0,0,0 }, +{ IDX_2C('a','u'), "オーストラリア", 0,0,0 }, +{ IDX_2C('a','w'), "アルバ", 0,0,0 }, +{ IDX_2C('a','z'), "アゼルバイジャン", 0,0,0 }, +{ IDX_2C('b','a'), "ボスニア・ヘルチゴビナ", 0,0,0 }, +{ IDX_2C('b','b'), "バルバドス", 0,0,0 }, +{ IDX_2C('b','d'), "バングラディシュ", 0,0,0 }, +{ IDX_2C('b','e'), "ベルギー", 0,0,0 }, +{ IDX_2C('b','f'), "ブルキナ・ファソ", 0,0,0 }, +{ IDX_2C('b','g'), "ブルガリア", 0,0,0 }, +{ IDX_2C('b','h'), "バハレーン", 0,0,0 }, +{ IDX_2C('b','i'), "ブルンディ", 0,0,0 }, +{ IDX_2C('b','j'), "ベナン", 0,0,0 }, +{ IDX_2C('b','m'), "バミューダ", 0,0,0 }, +{ IDX_2C('b','n'), "ブルネイ Darussalam", 0,0,0 }, +{ IDX_2C('b','o'), "ボリビア", 0,0,0 }, +{ IDX_2C('b','r'), "ブラジル", 0,0,0 }, +{ IDX_2C('b','s'), "バハマ", 0,0,0 }, +{ IDX_2C('b','t'), "ブータン", 0,0,0 }, +{ IDX_2C('b','v'), "Bouvet島", 0,0,0 }, +{ IDX_2C('b','w'), "ボツワナ", 0,0,0 }, +{ IDX_2C('b','y'), "ベラルーシ", 0,0,0 }, +{ IDX_2C('b','z'), "ベリーズ", 0,0,0 }, +{ IDX_2C('c','a'), "カナダ", 0,0,0 }, +{ IDX_2C('c','c'), "Cocos (Keeling)島", 0,0,0 }, +{ IDX_2C('c','f'), "中央アフリカ共和国", 0,0,0 }, +{ IDX_2C('c','g'), "コンゴ", 0,0,0 }, +{ IDX_2C('c','h'), "スイス", 0,0,0 }, +{ IDX_2C('c','i'), "象牙海岸共和国", 0,0,0 }, +{ IDX_2C('c','k'), "クック島", 0,0,0 }, +{ IDX_2C('c','l'), "チリ", 0,0,0 }, +{ IDX_2C('c','m'), "カメルーン", 0,0,0 }, +{ IDX_2C('c','n'), "中華人民共和国", 0,0,0 }, +{ IDX_2C('c','o'), "コロンビア", 0,0,0 }, +{ IDX_2C('c','r'), "コスタリカ", 0,0,0 }, +{ IDX_2C('c','s'), "(旧)チェコスロバキア", 0,0,0 }, +{ IDX_2C('c','u'), "キューバ", 0,0,0 }, +{ IDX_2C('c','v'), "カーボ・ヴルディ", 0,0,0 }, +{ IDX_2C('c','x'), "クリスマス島", 0,0,0 }, +{ IDX_2C('c','y'), "サイプラス王国", 0,0,0 }, +{ IDX_2C('c','z'), "チェコ", 0,0,0 }, +{ IDX_2C('d','e'), "ドイツ", 0,0,0 }, +{ IDX_2C('d','j'), "ジブティ", 0,0,0 }, +{ IDX_2C('d','k'), "デンマーク", 0,0,0 }, +{ IDX_2C('d','m'), "ドミニカ", 0,0,0 }, +{ IDX_2C('d','o'), "ドミニカ共和国", 0,0,0 }, +{ IDX_2C('d','z'), "アルジェリア", 0,0,0 }, +{ IDX_2C('e','c'), "エクアドル", 0,0,0 }, +{ IDX_2C('e','e'), "エストニア", 0,0,0 }, +{ IDX_2C('e','g'), "エジプト", 0,0,0 }, +{ IDX_2C('e','h'), "西サハラ", 0,0,0 }, +{ IDX_2C('e','r'), "エリトリア", 0,0,0 }, +{ IDX_2C('e','s'), "スペイン", 0,0,0 }, +{ IDX_2C('e','t'), "エチオピア", 0,0,0 }, +{ IDX_2C('f','i'), "フィンランド", 0,0,0 }, +{ IDX_2C('f','j'), "フィジー", 0,0,0 }, +{ IDX_2C('f','k'), "フォークランド諸島(Malvinas)", 0,0,0 }, +{ IDX_2C('f','m'), "ミクロネシア連邦", 0,0,0 }, +{ IDX_2C('f','o'), "Faroe 諸島", 0,0,0 }, +{ IDX_2C('f','r'), "フランス", 0,0,0 }, +{ IDX_2C('f','x'), "フランス, メトロポリタン", 0,0,0 }, +{ IDX_2C('g','a'), "ガボン", 0,0,0 }, +{ IDX_2C('g','b'), "イギリス(UK)", 0,0,0 }, +{ IDX_2C('g','d'), "グレナダ", 0,0,0 }, +{ IDX_2C('g','e'), "グルジア", 0,0,0 }, +{ IDX_2C('g','f'), "フランス Guiana", 0,0,0 }, +{ IDX_2C('g','h'), "ガーナ", 0,0,0 }, +{ IDX_2C('g','i'), "ジブラルタル", 0,0,0 }, +{ IDX_2C('g','l'), "グリーンランド", 0,0,0 }, +{ IDX_2C('g','m'), "ガンビア", 0,0,0 }, +{ IDX_2C('g','n'), "ギニア", 0,0,0 }, +{ IDX_2C('g','p'), "グアデルーペ", 0,0,0 }, +{ IDX_2C('g','q'), "赤道ギニア", 0,0,0 }, +{ IDX_2C('g','r'), "ギリシャ", 0,0,0 }, +{ IDX_2C('g','s'), "S.ジョージア・S.サンドウィッチ諸島", 0,0,0 }, +{ IDX_2C('g','t'), "グアティマラ", 0,0,0 }, +{ IDX_2C('g','u'), "グアム", 0,0,0 }, +{ IDX_2C('g','w'), "ギニア・ビサウ", 0,0,0 }, +{ IDX_2C('g','y'), "ガイアナ", 0,0,0 }, +{ IDX_2C('h','k'), "香港", 0,0,0 }, +{ IDX_2C('h','m'), "Heard・McDonald諸島", 0,0,0 }, +{ IDX_2C('h','n'), "ホンジェラス", 0,0,0 }, +{ IDX_2C('h','r'), "クロアチア(Hrvatska)", 0,0,0 }, +{ IDX_2C('h','t'), "ハイチ", 0,0,0 }, +{ IDX_2C('h','u'), "ハンガリー", 0,0,0 }, +{ IDX_2C('i','d'), "インドネシア", 0,0,0 }, +{ IDX_2C('i','e'), "アイルランド", 0,0,0 }, +{ IDX_2C('i','l'), "イスラエル", 0,0,0 }, +{ IDX_2C('i','n'), "インド", 0,0,0 }, +{ IDX_2C('i','o'), "イギリス インド海域", 0,0,0 }, +{ IDX_2C('i','q'), "イラク", 0,0,0 }, +{ IDX_2C('i','r'), "イラン", 0,0,0 }, +{ IDX_2C('i','s'), "アイスランド", 0,0,0 }, +{ IDX_2C('i','t'), "イタリア", 0,0,0 }, +{ IDX_2C('j','m'), "ジャマイカ", 0,0,0 }, +{ IDX_2C('j','o'), "ヨルダン", 0,0,0 }, +{ IDX_2C('j','p'), "日本", 0,0,0 }, +{ IDX_2C('k','e'), "ケニア", 0,0,0 }, +{ IDX_2C('k','g'), "キリギスタン", 0,0,0 }, +{ IDX_2C('k','h'), "カンボジア", 0,0,0 }, +{ IDX_2C('k','i'), "キリバス", 0,0,0 }, +{ IDX_2C('k','m'), "コモロ", 0,0,0 }, +{ IDX_2C('k','n'), "Saint Kitts and Nevis", 0,0,0 }, +{ IDX_2C('k','p'), "北朝鮮", 0,0,0 }, +{ IDX_2C('k','r'), "大韓民国", 0,0,0 }, +{ IDX_2C('k','w'), "クエート", 0,0,0 }, +{ IDX_2C('k','y'), "ケイマン諸島", 0,0,0 }, +{ IDX_2C('k','z'), "カザフスタン", 0,0,0 }, +{ IDX_2C('l','a'), "ラオス", 0,0,0 }, +{ IDX_2C('l','b'), "レバノン", 0,0,0 }, +{ IDX_2C('l','c'), "Saint Lucia", 0,0,0 }, +{ IDX_2C('l','i'), "リヒレンシュタイン", 0,0,0 }, +{ IDX_2C('l','k'), "スリランカ", 0,0,0 }, +{ IDX_2C('l','r'), "リベリア", 0,0,0 }, +{ IDX_2C('l','s'), "レソト", 0,0,0 }, +{ IDX_2C('l','t'), "リトアニア", 0,0,0 }, +{ IDX_2C('l','u'), "ルクセンブルク", 0,0,0 }, +{ IDX_2C('l','v'), "ラトビア", 0,0,0 }, +{ IDX_2C('l','y'), "リビア", 0,0,0 }, +{ IDX_2C('m','a'), "モロッコ", 0,0,0 }, +{ IDX_2C('m','c'), "モナコ", 0,0,0 }, +{ IDX_2C('m','d'), "モルドバ", 0,0,0 }, +{ IDX_2C('m','g'), "マダガスカル", 0,0,0 }, +{ IDX_2C('m','h'), "マーシャル諸島", 0,0,0 }, +{ IDX_2C('m','k'), "マケドニア", 0,0,0 }, +{ IDX_2C('m','l'), "マリ", 0,0,0 }, +{ IDX_2C('m','m'), "ミャンマー", 0,0,0 }, +{ IDX_2C('m','n'), "モンゴル", 0,0,0 }, +{ IDX_2C('m','o'), "マカウ", 0,0,0 }, +{ IDX_2C('m','p'), "北マリアナ諸島", 0,0,0 }, +{ IDX_2C('m','q'), "Martinique", 0,0,0 }, +{ IDX_2C('m','r'), "モーリタニア", 0,0,0 }, +{ IDX_2C('m','s'), "モントセルラット", 0,0,0 }, +{ IDX_2C('m','t'), "マルタ", 0,0,0 }, +{ IDX_2C('m','u'), "モーリシャス", 0,0,0 }, +{ IDX_2C('m','v'), "モルディヴ", 0,0,0 }, +{ IDX_2C('m','w'), "マワウィ", 0,0,0 }, +{ IDX_2C('m','x'), "メキシコ", 0,0,0 }, +{ IDX_2C('m','y'), "マレーシア", 0,0,0 }, +{ IDX_2C('m','z'), "モザンビーク", 0,0,0 }, +{ IDX_2C('n','a'), "ナミビア", 0,0,0 }, +{ IDX_2C('n','c'), "ニューカレドニア", 0,0,0 }, +{ IDX_2C('n','e'), "ニジェール", 0,0,0 }, +{ IDX_2C('n','f'), "ノーフォーク島", 0,0,0 }, +{ IDX_2C('n','g'), "ナイジェリア", 0,0,0 }, +{ IDX_2C('n','i'), "ニカラグア", 0,0,0 }, +{ IDX_2C('n','l'), "オランダ", 0,0,0 }, +{ IDX_2C('n','o'), "ノルウェー", 0,0,0 }, +{ IDX_2C('n','p'), "ネパール", 0,0,0 }, +{ IDX_2C('n','r'), "ナウル", 0,0,0 }, +{ IDX_2C('n','t'), "自然領域", 0,0,0 }, +{ IDX_2C('n','u'), "ニウエ", 0,0,0 }, +{ IDX_2C('n','z'), "ニュージーランド (Aotearoa)", 0,0,0 }, +{ IDX_2C('o','m'), "オーマン", 0,0,0 }, +{ IDX_2C('p','a'), "パナマ", 0,0,0 }, +{ IDX_2C('p','e'), "ペルー", 0,0,0 }, +{ IDX_2C('p','f'), "フランス ポリネシア", 0,0,0 }, +{ IDX_2C('p','g'), "パプアニューギニア", 0,0,0 }, +{ IDX_2C('p','h'), "フィリピン", 0,0,0 }, +{ IDX_2C('p','k'), "パキスタン", 0,0,0 }, +{ IDX_2C('p','l'), "ポーランド", 0,0,0 }, +{ IDX_2C('p','m'), "St. Pierre and Miquelon", 0,0,0 }, +{ IDX_2C('p','n'), "Pitcairn", 0,0,0 }, +{ IDX_2C('p','r'), "プエルトリコ", 0,0,0 }, +{ IDX_2C('p','t'), "ポルトガル", 0,0,0 }, +{ IDX_2C('p','w'), "パラオ", 0,0,0 }, +{ IDX_2C('p','y'), "パラグアイ", 0,0,0 }, +{ IDX_2C('q','a'), "カタル", 0,0,0 }, +{ IDX_2C('r','e'), "Reunion", 0,0,0 }, +{ IDX_2C('r','o'), "ルーマニア", 0,0,0 }, +{ IDX_2C('r','u'), "ロシア共和国", 0,0,0 }, +{ IDX_2C('r','w'), "ルワンダ", 0,0,0 }, +{ IDX_2C('s','a'), "サウジアラビア王国", 0,0,0 }, +{ IDX_2C('s','B'), "ソロモン諸島", 0,0,0 }, +{ IDX_2C('s','c'), "セイシェル", 0,0,0 }, +{ IDX_2C('s','d'), "スーダン", 0,0,0 }, +{ IDX_2C('s','e'), "スウェーデン", 0,0,0 }, +{ IDX_2C('s','g'), "シンガポール", 0,0,0 }, +{ IDX_2C('s','h'), "セント・ヘレナ", 0,0,0 }, +{ IDX_2C('s','i'), "スロベニア", 0,0,0 }, +{ IDX_2C('s','j'), "Svalbard・Jan Mayen諸島", 0,0,0 }, +{ IDX_2C('s','k'), "スロバキア共和国", 0,0,0 }, +{ IDX_2C('s','l'), "シエラ・レオーネ", 0,0,0 }, +{ IDX_2C('s','m'), "サンマリノ", 0,0,0 }, +{ IDX_2C('s','n'), "セネガル", 0,0,0 }, +{ IDX_2C('s','o'), "ソマリア", 0,0,0 }, +{ IDX_2C('s','r'), "スリナム", 0,0,0 }, +{ IDX_2C('s','t'), "サントメ・プリンシペ", 0,0,0 }, +{ IDX_2C('s','u'), "(旧)ソビエト連邦", 0,0,0 }, +{ IDX_2C('s','v'), "El Salvador", 0,0,0 }, +{ IDX_2C('s','y'), "リシア", 0,0,0 }, +{ IDX_2C('s','z'), "スワジランド", 0,0,0 }, +{ IDX_2C('t','c'), "タークス・カイコス群島", 0,0,0 }, +{ IDX_2C('t','d'), "チャード", 0,0,0 }, +{ IDX_2C('t','f'), "French Southern Territories", 0,0,0 }, +{ IDX_2C('t','g'), "トーゴー", 0,0,0 }, +{ IDX_2C('t','h'), "タイ", 0,0,0 }, +{ IDX_2C('t','j'), "タジキスタン", 0,0,0 }, +{ IDX_2C('t','k'), "Tokelau", 0,0,0 }, +{ IDX_2C('t','m'), "トルクメニスタン", 0,0,0 }, +{ IDX_2C('t','n'), "チュニジア", 0,0,0 }, +{ IDX_2C('t','o'), "トンガ", 0,0,0 }, +{ IDX_2C('t','p'), "East Timor", 0,0,0 }, +{ IDX_2C('t','r'), "トルコ", 0,0,0 }, +{ IDX_2C('t','t'), "トリニダッド・トバゴ", 0,0,0 }, +{ IDX_2C('t','v'), "トゥヴァル", 0,0,0 }, +{ IDX_2C('t','w'), "台湾", 0,0,0 }, +{ IDX_2C('t','z'), "タンザニア", 0,0,0 }, +{ IDX_2C('u','a'), "ウクライナ", 0,0,0 }, +{ IDX_2C('u','g'), "ウガンダ", 0,0,0 }, +{ IDX_2C('u','k'), "イギリス", 0,0,0 }, +{ IDX_2C('u','m'), "アメリカ Minor Outlying諸島", 0,0,0 }, +{ IDX_2C('u','s'), "アメリカ合州国", 0,0,0 }, +{ IDX_2C('u','y'), "ウルグアイ", 0,0,0 }, +{ IDX_2C('u','z'), "ウズベキスタン", 0,0,0 }, +{ IDX_2C('v','a'), "バチカン(Holy See)", 0,0,0 }, +{ IDX_2C('v','c'), "セントビンセント・グレナディーン諸島", 0,0,0 }, +{ IDX_2C('v','e'), "ベネズエラ", 0,0,0 }, +{ IDX_2C('v','g'), "バージン諸島 (イギリス)", 0,0,0 }, +{ IDX_2C('v','i'), "バージン諸島 (アメリカ)", 0,0,0 }, +{ IDX_2C('v','n'), "ベトナム", 0,0,0 }, +{ IDX_2C('v','u'), "ヴァヌアツ", 0,0,0 }, +{ IDX_2C('w','f'), "ワリス・フツナ諸島", 0,0,0 }, +{ IDX_2C('w','s'), "サモア", 0,0,0 }, +{ IDX_2C('y','e'), "イエメン", 0,0,0 }, +{ IDX_2C('y','t'), "マヨテ", 0,0,0 }, +{ IDX_2C('y','u'), "ユーゴスラビア", 0,0,0 }, +{ IDX_2C('z','a'), "南アフリカ", 0,0,0 }, +{ IDX_2C('z','m'), "ザンビア", 0,0,0 }, +{ IDX_2C('z','r'), "ザイール", 0,0,0 }, +{ IDX_2C('z','w'), "ジンバビエ", 0,0,0 }}; + +#define MAX_CTRY (int)(sizeof(ctry)/sizeof(struct country_code)) diff -Nur webalizer-1.30-04/webalizer.c webalizer-1.30-04-jp/webalizer.c --- webalizer-1.30-04/webalizer.c Mon Jul 12 02:36:10 1999 +++ webalizer-1.30-04-jp/webalizer.c Sun Dec 12 04:25:00 1999 @@ -1817,11 +1817,21 @@ now = time(NULL); /* convert to timestamp string */ if (local_time) +#ifndef JAPANESE strftime(timestamp,sizeof(timestamp),"%d-%b-%Y %H:%M %Z", localtime(&now)); +#else + strftime(timestamp,sizeof(timestamp),msg_hhdr_date, + localtime(&now)); +#endif else +#ifndef JAPANESE strftime(timestamp,sizeof(timestamp),"%d-%b-%Y %H:%M GMT", gmtime(&now)); +#else + strftime(timestamp,sizeof(timestamp),msg_hhdr_gmtdate, + localtime(&now)); +#endif return timestamp; } @@ -1964,7 +1974,11 @@ char htitle[256]; if (verbose>1) +#ifndef JAPANESE printf("%s %s %d\n",msg_gen_rpt, l_month[cur_month-1], cur_year); +#else + printf("%s %d%s %s\n",msg_gen_rpt, cur_year, msg_year, l_month[cur_month-1]); +#endif /* update history */ i=cur_month-1; @@ -1981,11 +1995,15 @@ /* fill in filenames */ sprintf(html_fname,"usage_%04d%02d.%s",cur_year,cur_month,html_ext); - sprintf(gif1_fname,"daily_usage_%04d%02d.gif",cur_year,cur_month); - sprintf(gif2_fname,"hourly_usage_%04d%02d.gif",cur_year,cur_month); + sprintf(gif1_fname,"daily_usage_%04d%02d.png",cur_year,cur_month); + sprintf(gif2_fname,"hourly_usage_%04d%02d.png",cur_year,cur_month); /* create GIF images for web page */ +#ifndef JAPANESE sprintf(dtitle,"%s %s %d",msg_hmth_du,l_month[cur_month-1],cur_year); +#else + sprintf(dtitle,"%s %d%s %s",msg_hmth_du,cur_year,msg_year,l_month[cur_month-1]); +#endif month_graph6 ( gif1_fname, /* filename */ dtitle, /* graph title */ @@ -2000,7 +2018,11 @@ if (hourly_graph) { +#ifndef JAPANESE sprintf(htitle,"%s %s %d",msg_hmth_hu,l_month[cur_month-1],cur_year); +#else + sprintf(htitle,"%s %d%s %s",msg_hmth_hu,cur_year,msg_year,l_month[cur_month-1]); +#endif day_graph3( gif2_fname, htitle, th_hit, @@ -2015,7 +2037,11 @@ fprintf(stderr,"%s %s\n",msg_no_open,html_fname); return 1; } +#ifndef JAPANESE sprintf(buffer,"%s %d",l_month[cur_month-1],cur_year); +#else + sprintf(buffer,"%d%s %s",cur_year,msg_year, l_month[cur_month-1]); +#endif write_html_head(buffer); month_links(); month_total_table(); @@ -2099,9 +2125,15 @@ fprintf(out_fp,"\n"); fprintf(out_fp,"\n"); +#ifndef JAPANESE fprintf(out_fp,"\n", GREY,msg_mtot_ms,l_month[cur_month-1],cur_year); +#else + fprintf(out_fp,"\n", + GREY,msg_mtot_ms,cur_year,msg_year,l_month[cur_month-1]); +#endif fprintf(out_fp,"\n"); /* Total Hits */ fprintf(out_fp,"\n" \ @@ -2242,9 +2274,15 @@ fprintf(out_fp,"
" \ "%s %s %d
" \ + "%s %d%s %s
%s
\n"); fprintf(out_fp,"\n"); /* Daily statistics for ... */ +#ifndef JAPANESE fprintf(out_fp,"\n", GREY,msg_dtot_ds,l_month[cur_month-1], cur_year); +#else + fprintf(out_fp,"\n", + GREY,msg_dtot_ds,cur_year,msg_year,l_month[cur_month-1]); +#endif fprintf(out_fp,"\n"); fprintf(out_fp,"\n" \ @@ -2324,9 +2362,15 @@ fprintf(out_fp,"\n"); fprintf(out_fp,"
" \ "%s %s %d
" \ + "%s %d%s %s
" \ "%s
\n"); fprintf(out_fp,"\n"); +#ifndef JAPANESE fprintf(out_fp,"\n", GREY,msg_htot_hs,l_month[cur_month-1], cur_year); +#else + fprintf(out_fp,"\n", + GREY,msg_htot_hs,cur_year,msg_year,l_month[cur_month-1]); +#endif fprintf(out_fp,"\n"); fprintf(out_fp,"\n" \ @@ -2456,6 +2500,7 @@ fprintf(out_fp,"
"\ "%s %s %d
"\ + "%s %d%s %s
" \ "%s
\n"); fprintf(out_fp,"\n"); +#ifndef JAPANESE if (flag) fprintf(out_fp,"\n", GREY, msg_top_top,tot_num,msg_top_of, @@ -2463,6 +2508,15 @@ else fprintf(out_fp,"\n", GREY,msg_top_top, tot_num, msg_top_of, t_site, msg_top_s); +#else + if (flag) fprintf(out_fp,"\n", + GREY, msg_top_of,t_site,msg_top_s,msg_top_top, + tot_num,msg_h_xfer,msg_h_by); + else fprintf(out_fp,"\n", + GREY, msg_top_of, t_site, msg_top_s, msg_top_top, tot_num); +#endif fprintf(out_fp,"\n"); fprintf(out_fp,"\n",GREY); @@ -2573,6 +2627,7 @@ fprintf(out_fp,"
" \ "%s %d %s %lu %s %s %s
" \ "%s %d %s %lu %s
" \ + "%s %lu %s %s %d (%s%s)
" \ + "%s %lu %s %s %d
" \ "#
\n"); fprintf(out_fp,"\n"); +#ifndef JAPANESE if (flag) fprintf(out_fp,"\n", GREY,msg_top_top,tot_num,msg_top_of, @@ -2580,6 +2635,15 @@ else fprintf(out_fp,"\n", GREY,msg_top_top,tot_num,msg_top_of,t_url,msg_top_u); +#else + if (flag) fprintf(out_fp,"\n", + GREY,msg_top_of,t_url,msg_top_u,msg_top_top, + tot_num,msg_h_xfer,msg_h_by); + else fprintf(out_fp,"\n", + GREY, msg_top_of, t_url, msg_top_u, msg_top_top, tot_num); +#endif fprintf(out_fp,"\n"); fprintf(out_fp,"\n", @@ -2716,10 +2780,16 @@ fprintf(out_fp,"
" \ "%s %d %s %lu %s %s %s
" \ "%s %d %s %lu %s
" \ + "%s %lu %s %s %d (%s%s)
" \ + "%s %lu %s %s %d
" \ "#
\n"); fprintf(out_fp,"\n"); +#ifndef JAPANESE fprintf(out_fp,"\n", GREY,msg_top_top,tot_dsp,msg_top_of, tot_cnt,(flag)?msg_top_ex:msg_top_en); +#else + fprintf(out_fp,"\n", + GREY,msg_top_of,tot_cnt,(flag)?msg_top_ex:msg_top_en,msg_top_top,tot_dsp); +#endif fprintf(out_fp,"\n"); fprintf(out_fp,"\n", @@ -2818,9 +2888,15 @@ fprintf(out_fp,"\n"); fprintf(out_fp,"
" \ "%s %d %s %d %s
" \ + "%s %d %s %s %d
" \ "#
\n"); fprintf(out_fp,"\n"); +#ifndef JAPANESE fprintf(out_fp,"\n", GREY, msg_top_top, tot_num, msg_top_of, t_ref, msg_top_r); +#else + fprintf(out_fp,"\n", + GREY, msg_top_of, t_ref, msg_top_r, msg_top_top, tot_num); +#endif fprintf(out_fp,"\n"); fprintf(out_fp,"\n", @@ -2912,9 +2988,15 @@ fprintf(out_fp,"\n"); fprintf(out_fp,"
" \ "%s %d %s %lu %s
" \ + "%s %lu %s %s %d
" \ "#
\n"); fprintf(out_fp,"\n"); +#ifndef JAPANESE fprintf(out_fp,"\n", GREY, msg_top_top, tot_num, msg_top_of, t_agent, msg_top_a); +#else + fprintf(out_fp,"\n", + GREY, msg_top_of, t_agent, msg_top_a, msg_top_top, tot_num); +#endif fprintf(out_fp,"\n"); fprintf(out_fp,"\n", @@ -3124,8 +3206,12 @@ pie_data[i]=top_ctrys[i]->count; /* load the array */ pie_legend[i]=top_ctrys[i]->desc; } +#ifndef JAPANESE sprintf(pie_title,"%s %s %d",msg_ctry_use,l_month[cur_month-1],cur_year); - sprintf(pie_fname,"ctry_usage_%04d%02d.gif",cur_year,cur_month); +#else + sprintf(pie_title,"%s %d%s %s",msg_ctry_use,cur_year,msg_year,l_month[cur_month-1]); +#endif + sprintf(pie_fname,"ctry_usage_%04d%02d.png",cur_year,cur_month); pie_chart(pie_fname,pie_title,t_hit,pie_data,pie_legend); /* do it */ @@ -3138,9 +3224,15 @@ for (i=0;icount!=0) tot_num++; fprintf(out_fp,"
" \ "%s %d %s %lu %s
" \ + "%s %lu %s %s %d
" \ "#
\n"); fprintf(out_fp,"\n"); +#ifndef JAPANESE fprintf(out_fp,"\n", GREY,msg_top_top,tot_num,msg_top_of,tot_ctry,msg_top_c); +#else + fprintf(out_fp,"\n", + GREY,msg_top_of,tot_ctry,msg_top_c,msg_top_top,tot_num); +#endif fprintf(out_fp,"\n"); fprintf(out_fp,"\n",GREY); @@ -3213,7 +3305,7 @@ i=(s_mth==12)?1:s_mth+1; - year_graph6x( "usage.gif", /* filename */ + year_graph6x( "usage.png", /* filename */ buffer, /* graph title */ i, /* last month */ hist_hit, /* data set 1 */ @@ -3234,7 +3326,7 @@ } write_html_head(msg_main_per); /* year graph */ - fprintf(out_fp,"\"%s\"

\n",buffer); /* month table */ fprintf(out_fp,"

" \ "%s %d %s %d %s
" \ + "%s %d %s %s %d
" \ "#
\n"); @@ -3274,10 +3366,17 @@ if (--s_mth < 0) s_mth = 11; if ((hist_month[s_mth]==0) && (hist_files[s_mth]==0)) continue; days_in_month=(hist_lday[s_mth]-hist_fday[s_mth])+1; +#ifndef JAPANESE fprintf(out_fp,"\n", hist_year[s_mth], hist_month[s_mth], html_ext, s_month[hist_month[s_mth]-1], hist_year[s_mth]); +#else + fprintf(out_fp,"\n", + hist_year[s_mth], hist_month[s_mth], html_ext, + hist_year[s_mth],msg_year, s_month[hist_month[s_mth]-1] ); +#endif fprintf(out_fp,"\n", hist_hit[s_mth]/days_in_month); fprintf(out_fp,"\n",
" \ "%s %d
" \ + "%d%s %s%lu%lu