#!/usr/bin/perl #use CGI::Carp qw(fatalsToBrowser); #------------------------------------------ # FFXI Member Registration System # Version 0.67(07/11/21) # script by seno 2002-2007 # webmaster@senobeya.com # 著作権表示は消すなとかしょうもないことは # 言わないのですヨ。好きにしてよし! #------------------------------------------ #壁紙画像サンプルは #フリー素材集 壁紙工房 Giggurat/Information #http://www.chaldea.ne.jp/atelier/ #のものを使用させていただいております。 #BBSPainterは #ば科学的愛情(http://www.geocities.co.jp/SiliconValley-SanJose/8609/) #のJAVAアプレットです。 # #各種サブルーチンファイル #keitai.pl 携帯対応ルーチン #master.pl マスターモード #table.pl 表出力ルーチン #設定類(0.5より各種の設定はsetup.cgiに移動しました) $ENV{'TZ'} = "JST-9"; # $lockdir=""; とすることで、ファイルロックをしません。 # ただしデータ消滅の危険度は飛躍的に高くなります。 # バックアップを取るなどの対応をしてください。 $lockdir="lock"; #バージョン番号。いじらないでネ。改造した場合は適当にどうぞ。 $version="Version 0.67"; #このスクリプトのなまえ。ファイル名を変更したときはここも変更してください。 $script="guildmember.cgi"; $script2="admin.cgi"; #設定ファイル読み出し require "setup.cgi"; #ミッション名(英語未対応)とある冒険者さん作成のリストです。 if($language ne "English"){ @mpointword=('基本','グループ1','グループ2','総消費メリットポイント','カテゴリ上限'); @assaultword=('移送の幻灯','傭兵ランク','Leujaom','MammolJa','Leberos','Perqia','Ilrusi','Nyzul','二','一','上','長','伍','軍','曹','特','少','中','大'); @amlist=('','聖蛇の国',"不滅の防人",'山猫の社長',"黄金の騎士",'王子の告白','東風','西風','傭兵のつとめ','聖跡の巡視','星気の笛音','双蛇の謀','無手の傀儡師','亡国の墳墓','海豚の紋章','漆黒の柩','幽冥の海賊','賓客の資格','泡沫の宝冠','遇人の内懐','茶屋の厄難','千古の渦紋','特使の御楯','宴遊の終幕','悪魔と悪鬼と','運命の歯車','魔蛇の封蝋','貴人の失踪','古寺の所縁','少女の傀儡','海賊の利','暗雲の去来','逢魔が時','砂上の楼閣','山猫の皮算用','亡国の遺産','天狗の慧眼','修羅の道','戦乱の兆し','連合の混迷','紐解ける理','審判の光','巨人の懐へ','蒼獅子の最期','少女の決意','ラグナロク','戴冠の儀','大団円','永遠の傭兵'); @aslist=('傭兵ランク','ルジャワン霊窟開通','マムージャ兵訓練所開通','レベロス風穴開通','ペリキア開通','イルルシ環礁開通','ル二等:ルジャワン掃討作戦','ル一等:オリハルコン鉱脈調査','ル上等:クラボエール男爵警護','マ二等:皇国エージェント救出作戦','マ一等:秘密訓練所急襲作戦','マ上等:賢哲王暗殺作戦','レ二等:土竜作戦','レ一等:レベロス補給作戦','レ上等:落ち武者追撃戦','ペ二等:海猫護送作戦','ペ一等:レクイエム作戦','ペ上等:ライアーフ捜索作戦','イ二等:黄金の遺産収集作戦','イ一等:ラミア13号討伐作戦','イ上等:蠱物駆除作戦','ル兵長:シャナーハ草保護作戦 ','ル伍長:黒羊買付作戦','マ兵長:慰問物資強奪作戦 ','マ伍長:二重スパイ捕縛作戦','レ兵長:土筆作戦 ','レ伍長:傭兵軍師狙撃作戦','ペ兵長:黒い男爵撃墜作戦','ペ伍長:ペリキア架橋作戦','イ兵長:イルルシ掃海作戦','イ伍長:シーラット送迎作戦 ','ル軍曹:補給物資奪還指令 ','ル曹長:青の治験','マ軍曹:魔宝石回収指令 ','マ曹長:謝鱗祭襲撃作戦','レ軍曹:アプカル繁殖指令 ','レ曹長:ワモーラファーム襲撃作戦','ペ軍曹:ブラッドバス計画抑止作戦 ','ペ曹長:地雷原処理作戦','イ軍曹:アプカル捕獲指令戦 ','イ曹長:指輪捜索指令 ','ル特務:オグマ奪取指令','マ特務:マーリドガーデン作戦','レ特務:ハンターキラー作戦','ペ特務:双頭の蛇作戦','イ特務:脱走兵武装解除指令','ル少尉:不滅隊・魔滅隊合同演習','マ少尉:青の症例','レ少尉:ブラックパール作戦','ペ少尉:人形の目覚め作戦','イ少尉:鱆号作戦','ル中尉:ヘルシング作戦','マ中尉:スサノオ作戦','レ中尉:ヘラクレス作戦','ペ中尉:キラーロード作戦','イ中尉:ベレロフォン作戦'); @nzlist=('未開通','0','6','11','16','21','26','31','36','41','46','51','56','61','66','71','76','81','86','91','96'); @asrank=('','二等傭兵','一等傭兵','上等傭兵','傭兵長','伍長','軍曹','曹長','特務曹長','少尉','中尉','大尉'); @pmlist=('','1-1:命の洗礼','1-2:楼閣の下に','1-3:母なる石', '2-1:西への誘い','2-2:忘却の町','2-3:隔たれし信仰','2-4:とこしえに響く歌','2-5:誓いの雄叫び', '3-1:龍王の導き','3-2:主のなき都', '3-3-1-1:2つの道-瑠璃色の川','3-3-1-2:流転','3-3-1-3:累家の末流','3-3-1-4:ルーヴランスという者', '3-3-2-1:2つの道-をとめの記憶','3-3-2-2:をかしき祖国','3-3-2-3:をかしき再会','3-3-2-4:をかしき旅立ち', '3-4:戦慄き','3-5:神を名乗りて', '4-1:よりしろ','4-2:猛き者たちよ','4-3:礼拝の意味','4-4:そしりを受けつつも', '5-1:鍔音やむことなく','5-2:願わくば闇よ', '5-3-1-1:みっつの道-汝の罪は','5-3-1-2:南方の伝説','5-3-1-3:名捨て人ふたり','5-3-1-4:なにゆえにその子は','5-3-1-5:永いお別れ', '5-3-2-1:みっつの道-楽園を求めるは','5-3-2-2:螺旋','5-3-2-3:烙印ありて','5-3-2-4:礼賛者','5-3-2-5:羅針の示すもの', '5-3-3-1:みっつの道-群れ立つ使者は','5-3-3-2:結び目','5-3-3-3:向かい風','5-3-3-4:迎え火', '6-1:歌うは誰がため','6-2:ゐぬる場所','6-3:望むはあらゆる答え','6-4:畏れよ、我を', '7-1:鎖と絆','7-2:闇に炎','7-3:眦決して','7-4:決別の前','7-5:武士道とは', '8-1:古代の園','8-2:選ばれし死','8-3:天使達の抗い','8-4:暁', 'さらばでござる','究極魔法の起源','悠久の名を求め','メーガスの名は永遠に','澪標', '呪縛ほどけるとき','日輪を担いて','亡者の影','世界に在りて君は何を想うのか?','すべての終わりが閉ざされん' ); @jmlist=('','新たなる世界','海賊の巣窟ノーグ','カザム族長','ウガレピ寺院','古代石碑巡礼','流砂洞を越えて','神託の間','デルクフの塔再び','ロ・メーヴ','聖地ジ・タ〜滅びの神殿','神々の間','ミスラとクリスタル','神の扉トゥー・リア','アーク・ガーディアン','閉ざされし門','宿星の座','1万年の夢の終わりに','すべての終わりが閉ざされん'); @smlist=('-','1-1:オークの斥候を倒せ','1-2:コウモリ退治','1-3:子供の救助', '2-1:救助訓練','2-2:ダボイ調査報告','2-3:他国を回れ', '3-1:ダボイ潜入計画','3-2:クリスタルの泉','3-3:ジュノ大使館へ赴任', '4:魔晶石を奪え','5-1:廃墟フェ・イン','5-2:闇の王を討て!', '6-1:ローテ王妃の遺言','6-2:龍王の眠る場所', '7-1:教皇の威信','7-2:獣人兵器の秘密', '8-1:成人の儀','8-2:聖剣探索', '9-1:厚き壁','9-2:光の継承者', '10:全ミッション終了'); @bmlist=('-','1-1:ツェールン鉱山からの報告','1-2:彼の名はシド','1-3:終わらぬ戦い', '2-1:クリスタルライン','2-2:涸れ谷の怪物','2-3バストゥークを離れて', '3-1:四銃士','3-2:忘れられた鉱山にて','3-3:ジュノへ', '4:魔晶石を奪え','5-1:闇、再び','5-2:ザルカバードに眠る真実', '6-1:語り部現る!?','6-2:海賊たちの唄', '7-1:完成品のイメージ','7-2:それぞれの行方', '8-1:流砂の鎖','8-2:その記憶を紡ぐ者', '9-1:最後の幻想','9-2:双刃の邂逅', '10:全ミッション終了'); @wmlist=('-','1-1:ホルトト遺跡の大実験','1-2:カーディアンの心 ','1-3:平和のために', '2-1:白き書','2-2:試験の行方','2-3:三大強国', '3-1:それぞれの正義','3-2:星読み','3-3:新たなる旅立ち', '4:魔晶石を奪え','5-1:最後の護符','5-2:最果てにて君を待つ闇', '6-1:満月の泉','6-2:聖者の招待', '7-1:第6の院','7-2:蘇る神々', '8-1:ヴェイン','8-2:王と道化師', '9-1:死者の人形','9-2:月詠み', '10:全ミッション終了'); #デュナミス用 @maru=('×','○'); @mlist=( 'プロマシア','ジラート',"サンドリア",'バストゥーク','ウインダス',"デュナミス-サンドリア",'デュナミス-バストゥーク','デュナミス-ウインダス','デュナミス-ジュノ','デュナミス-ボスディン','デュナミス-ザルカバード','デュナミス-バルクルム','デュナミス-ブブリム','デュナミス-クフィム','デュナミス-タブナジア','アトルガン','アサルト','ナイズル'); } else { @mpointword=('General','Job Group1','Job group2','Total merit point use','Category Limit'); @assaultword=('RunicPortal','Mercenary Rank','Leujaom','MammolJa','Leberos','Perqia','Ilrusi','Nyzul','PSC','PFC','SP','LC','C','SER','SMJ','CS','SL'); @amlist=("","Land of Sacred Serpents","Immortal Sentries","President Salaheem","Knight of Gold","Confessions of Royalty","Easterly Winds","Westerly Winds","A Mercenary Life",'Undersea Scouting','Astral Waves','Imperial Schemes','Royal Puppeteer','Lost Kingdom','The Dolphin Crest','The Black Coffin','Ghosts of the Past','Guests of the Empire','Passing Glory','Sweets for the Soul','Teahouse Tumult','Finders Keepers','Shield of Diplomacy','Social Graces','Foiled Ambition','Playi,g the Part','Seal of the Serpent','Misplaced Nobility','Bastion of Knowledge','Puppet in Peril','Prevalence of Pirates','Shades of Vengeance','In the Blood',"Sentinels' Honor",'Testing the Waters','Legacy of the Lost','Gaze of the Saboteur','Path of Blood','Stirrings of War','Allied Rumblings','Unraveling Reason','Light of Judgment','Path of Darkness','Fangs of the Lion',"Nashmeira's Plea",'Ragnarok','Imperial Coronation','The Empress Crowned','Eternal Mercenary' ); @aslist=('Mercenary Rank','RunicPortal:Leujaoam','RunicPortal:Mamool Ja','RunicPortal:Lebros','RunicPortal:Periqia','RunicPortal:Ilrusi','LeuPSC:Leujaoam Cleansing','LeuPFC:Orichalcum Survey','LeuSP:Escort Professor Clavauert','MamPSC:Imperial Agent Rescue','MamPFC:Preemptive Strike','MamSP:Sagelord Elimination','LebPSC:Excavation Duty','LebPFC:Lebros Supplies','LebSP:Troll Fugitives','PerPSC:Seagull Grounded','PerPFC:Requiem','PerSP:Saving Private Ryaaf','IlrPSC:Golden Salvage','IlrPFC:Lamia No.13','IlrSP:Extermination','LeuLC:Shanarha Grass Conservation ','LeuC:Counting Sheep','MamLC:Breaking Morale ','MamC:The Double Agent','LebLC:Evade and Escape','LebC:Siegemaster Assassination','PerLC:Shooting Down the Baron','PerC:Building Bridges','IlrLC:Demolition Duty','IlrC:Searat Salvation','LeuSER:Supplies Recovery','LeuSMJ:Azure Experiments','MamSER:Imperial Treasure Retrieval','MamSMJ:Blitzkrieg','LebSER:Apkallu Breeding','LebSMJ:Wamoura Farm Raid','PerSER:Stop the Bloodshed','PerSMJ:Defuse the Threat','IlrSER:Apkallu Seizure','IlrSMJ:Lost and Found','LeuCS:Imperial Code','MamCS:Marids in the Mist','LebCS:Egg Conservation','PerCS:Operation: Snake Eyes','IlrCS:Deserter','LeuSL:Red Versus Blue','MamSL:Azure Ailments','LebSL:Operation: Black Pearl','PerSL:Wake the Puppet','IlrSL:Desperately Seeking Cephalopods','LeuFL:Bloody Rondo','MamFL:The Susanoo Shuffle','LebFL:Better than One','PerFL:The Price Is Right',"IlrFL:Bellerophon's Bliss"); @asrank=('','PSC','PFC','SP','LC','C','SER','SMJ','CS','SL','FL','CAP'); #@asrank=('','Private Second Class','Private First Class','Superior Private','LanceCorporal','Corporal','Sergent','SergentMajor','ChiefSergent','SecondLieutenant','FirstLieutenant','Captain'); @nzlist=('-','0','6','11','16','21','26','31','36','41','46','51','56','61','66','71','76','81','86','91','96'); @pmlist=('','1-1:The Rites of Life','1-2:Below the Arks','1-3:The Mothercrystals', '2-1:An Invitation West','2-2:The Lost City','2-3:Distant Beliefs','2-4:An Eternal Melody','2-5:Ancient Vows', '3-1:The Call of the Wyrmking','3-2:A Vessel Without a Captain', '3-3-1-1:The Road Forks-Emerald Waters','3-3-1-2:Vicissitudes','3-3-1-3:Descendents of Line Lost','3-3-1-4:Louverance', '3-3-2-1:The Road Forks-Memories of a Maiden','3-3-2-2:Comedy of Errors','3-3-2-3:Comedy of Errors','3-3-2-4:Exit Stage Left', '3-4:Tending Aged Wounds','3-5:Darkness Named', '4-1:Sheltering Doubt','4-2:The Savage','4-3:The Secrets of Worship','4-4:Slanderous Utterings', '5-1:The Enduring Tumult of War','5-2:Desires of Emptiness', '5-3-1-1:Three Forks-Past Sins','5-3-1-2:Southern Legend','5-3-1-3:Partners Without Fame','5-3-1-4:A Century of Hardship','5-3-1-5:Departures', '5-3-2-1:Three Forks-The Pursuit of Paradise','5-3-2-2:Spiral','5-3-2-3:Branded','5-3-2-4:Pride and Honor','5-3-2-5:And the Compass Guides', '5-3-3-1:Three Forks-Where Messengers Gather','5-3-3-2:Enlanglement','5-3-3-3:Head Wind','5-3-3-4:Flames for the Dead', '6-1:For Whom the Verse is Sung','6-2:A Place to Return','6-3:More Questions than Answers','6-4:One to be Feared', '7-1:Chains and Bonds','7-2:Flames in the Darkness','7-3:Fire in the Eyes of Men','7-4:Calm Before the Storm',"7-5:The Warrior's Path", '8-1:Garden of Antiquity','8-2:A Fate Decided','8-3:When Angels Fall','8-4:Dawn',"Storms of Fate","Shadows of the Departed","Apocalypse Nigh",'The Last Verse' ); @jmlist=('',"The New Frontier","Welcome t'Norg","Kazham's Chieftainness","The Temple of Uggalepih","Headstone Pilgrimage","Through the Quicksand Caves","The Chamber of Oracles","Return to Delkfutt's Tower","Ro'Maeve","The Temple of Desolation","The Hall of the Gods","The Mithra and the Crystal","The Gate of the Gods","Ark Angels","The Sealed Shrine","The Celestial Nexus","Awakening",'The Last Verse'); @smlist=('-',"Smash the Orcish Scouts ","Bat Hunt","Save the Children ","The Rescue Drill ","The Davoi Report ","Journey Abroad ","Infiltrate Davoi ","The Crystal Spring ","Appointment to Jeuno ","Magicite ","The Ruins of Fei'Yin ","The Shadow Lord ","Leaute's Last Wishes ","Ranperre's Final Rest ","Prestige of the Papsque ","The Secert Weapon ","Coming of Age ","Lightbringer ","Breaking Barriers ","The Heir to the Light ","RANK10"); @bmlist=('-',"The Zeruhn Report ","A Geological Survey ","Fetichism","The Crystal Line ","Wading Beasts ","The Emissary ","The Four Musketeers ","To the Forsaken Mines ","Jeuno ","Magicite ","Darkness Rising ","Xarcabard, Land of Truths ","Return of the Talekeeper ","The Pirates' Cove ","The Final Image ","On My Way ","The Chains that Bind Us ","Enter the Talekeeper ","The Salt of the Earth ","Where Two Paths Converge ","RANK10"); @wmlist=('-',"The Horuroro Ruins Experiment ","The Heart of the Matter ","The Price of Peace ","Lost for Words ","A Testing Time ","The Three Kingdoms ","To Each His Own Right ","Written in the Stars ","A New Journey ","Magicite ","The Final Seal ","The Shadow Awaits ","Full Moon Fountain ","Saintly Invitation ","The Sixth Ministry ","Awakening of the Gods ","Vain ","The Jester Who'd Be King ","Doll of the Dead ","Moon Reading ","RANK10"); #For Dynamis @maru=('-','Fin'); @mlist=( 'Promathia','Zilart',"Sand'Oria",'Bastok','Windurst',"Dynamis-Sand'Oria",'Dynamis-Bastok','Dynamis-Windurst','Dynamis-Jeuno','Dynamis-Beaucedine','Dynamis-Xarcabard','Dynamis-Valkurm','Dynamis-Buburimu','Dynamis-Qufim','Dynamis-Tavnazia',"Aht Urhgan","Assault"); } #日本語らいぶらり require './jcode.pl'; #画像らいぶらり require('image_getsize.pl'); $color[0]=$color0; $color[1]=$color1; $color[2]=$color2; $color[3]=$color3; $color[4]=$color4; $color[5]=$color5; $color[6]=$color6; $color[7]=$color7; $color[8]=$color8; $color[9]=$color9; $color[10]=$color10; #スキルランク # from FFXI skill capture(http://www.ausystem.org/~aushacho/gbox/ff/skill.html) #skilllist*** ='格短片両片両両両片両片両弓射投ガ回盾受神回強弱精暗歌弦管忍召青'); #skilllist*** ='闘剣剣剣斧斧鎌槍刀刀棍棍術撃擲ド避盾流聖復化体霊黒唱楽楽術喚魔'); $skillrank[0] ='D B-B B+A A+B+B-_ _ B-B D D D _ C C+C-_ _ _ _ _ _ _ _ _ _ _ _ '; #戦 $skillrank[1] ='A+_ _ _ _ _ _ _ _ _ C+B _ _ E A B+_ E _ _ _ _ _ _ _ _ _ _ _ _ '; #モ $skillrank[2] ='_ _ _ _ _ _ _ _ _ _ B+C+_ _ E _ E D _ A A+C+C _ _ _ _ _ _ _ _ '; #白 $skillrank[3] ='_ D _ _ _ _ E _ _ _ C+B-_ _ D _ E _ _ _ _ E C+A+A _ _ _ _ _ _ '; #黒 $skillrank[4] ='_ B B _ _ _ _ _ _ _ D _ D _ F _ D F E E C-B+A+C+E _ _ _ _ _ _ '; #赤 $skillrank[5] ='E A D _ _ _ _ _ _ _ E _ C-C+D _ A+F A _ _ _ _ _ _ _ _ _ _ _ _ '; #シ $skillrank[6] ='_ C-A+B _ _ _ E _ _ A A _ _ _ _ C A+C B+C D _ _ _ _ _ _ _ _ _ '; #ナ $skillrank[7] ='_ C B-A B-B-A+_ _ _ C-_ _ E _ _ C _ E _ _ _ C B+A _ _ _ _ _ _ '; #暗 $skillrank[8] ='_ B-D _ B-_ _ _ _ _ E _ A A C-_ E _ _ _ _ _ _ _ _ _ _ _ _ _ _ '; #狩 $skillrank[9] ='_ B-C-_ _ _ _ _ _ _ D C+_ _ E _ D _ E _ _ _ _ _ _ C C C _ _ _ '; #吟 $skillrank[10]='_ C+E _ A _ B-_ _ _ D _ _ _ _ _ C E C-_ _ _ _ _ _ _ _ _ _ _ _ '; #獣 $skillrank[11]='_ E C-_ _ _ _ A+_ _ E B-_ _ _ _ C-_ C-_ _ _ _ _ _ _ _ _ _ _ _ '; #竜 $skillrank[12]='_ E _ _ _ _ _ _ _ _ C+B _ _ _ _ E _ _ _ _ _ _ _ _ _ _ _ _ A _ '; #召 $skillrank[13]='E C+C _ _ _ _ _ A C-E _ E C A _ A _ A _ _ _ _ _ _ _ _ _ A _ _ '; #忍 $skillrank[14]='_ E C+_ _ _ _ B-_ A+E _ C+_ C+_ B+_ A _ _ _ _ _ _ _ _ _ _ _ _ '; #侍 $skillrank[15]='_ _ A _ _ _ _ _ _ _ B+_ _ _ _ _ C-_ D _ _ _ _ _ _ _ _ _ _ _ A+'; #青 $skillrank[16]='_ B+B-_ _ _ _ _ _ _ _ _ _ B C+_ D _ A _ _ _ _ _ _ _ _ _ _ _ _ '; #コ $skillrank[17]='C C-_ _ _ _ _ _ _ _ D _ _ _ C+B B _ D _ _ _ _ _ _ _ _ _ _ _ _ '; #か $skillrank[18]='D B D _ _ _ _ _ _ _ _ _ _ _ C _ B _ B _ _ _ _ _ _ _ _ _ _ _ _ '; #踊(暫定データ) $skillrank[19]='_ D _ _ _ _ _ _ _ _ C C _ _ D _ E _ E D D D D D D _ _ _ _ _ _ '; #学(暫定データ) #keyword read if(!open(IN,"$keyfile")){$key_avail=0;} @keyword=; close IN; # # MAIN ROUTINEs # $agent=$ENV{'HTTP_USER_AGENT'}; &form_read; &ip_ban; if( $agent =~ /J-PHONE/){ $ktai="on"; @user_agent = split(/\//,$ENV{'HTTP_USER_AGENT'}); if ($user_agent[1] >= 3) { $method="post"; } else { $method="get"; } } elsif( $agent =~ /DoCoMo/ || $agent =~ /Vodafone/ || $agent =~ /UP.Browser/ || $agent =~ /SoftBank/){ $ktai="on"; $method="post"; } else { $brawser="PC"; # $method="post enctype='multipart/form-data' "; $method="post"; } if($function eq "rss"){ &rss_write; &header; &list; } if($ktai eq "on"){&keitai;} if($function eq $button[0]){ #PROFED &set_cookie; &login; } elsif($function eq 'meritpoint' && $mpoint == 1){ &set_cookie; require("mpoint.pl"); &main_mpoint; } elsif($function eq 'customfield'){ &set_cookie; &custom_field; } elsif($function eq 'regist_word' && $key_avail == 1){ &set_cookie; ®ist_word; } elsif($function eq 'send' && $mes_avail == 1){ &set_cookie; &send_message; } elsif($function eq 'check' && $mes_avail == 1){ &set_cookie; &check_message; } elsif($function eq "new"){ #NEWREG &set_cookie; &header; &new_regist; } elsif($function eq $button[1]){ #DWRITE &set_cookie; &write_diary; } elsif($function eq "editdiary"){ #DMODIF &set_cookie; &edit_diary; } elsif($function eq "resdiary"){ #RESDIA &get_cookie; &res_diary; } elsif($function eq "faq"){ &header; &faq; } elsif($function eq "prof" || $function eq "profdetail" || $function eq "profdetail2"){ &get_cookie; &c_check; $topic="Profile:$name -$topic"; &header; if($c_match){ &prof;} } elsif($function eq "master"){ &header; require("master.pl"); &master; } else { &get_cookie; &c_check; &header; &list; } &footer; # # SUB ROUTINE # # #単語登録 # sub regist_word{ if(!open(IN,"$datafile")){&header; &error_message('datafile error/system','data file access failed.');} @all=; close IN; $match=""; foreach $i(@all){ ($r_no,$r_name,$r_pass,$r_dummy)=split(/\t/,$i); if($r_name eq $name && $pass eq $r_pass){ $match=$i; } } if($match eq ""){&header; &error_message('id/pass error','access failed.');} if($mode ne "regist"){ &header; print <<"EOM";
キーワード追加

ワード追加(確認なしで激しく追加)
キーワード
ふりがな
説明
Go Top
進行状況

新規日記および日記修正時にキーワードに自動リンク

キーワードページにはヒストリが追加されます。
レスには非対応というかわざと対応してない。

今後の予\定
キーワード内容追加
ヒストリ件数制御

キーワードリスト
EOM foreach $i(@keyword){ ($km,$kno)=split(/\t/,$i); print "$km
"; } } else { #ワード登録 if($title eq ""){&header; &error_message('no dat 385','data file access failed.');} $maxno=$#keyword+2; push(@keyword,"$title\t$maxno\t\n"); if(!open(OUT,">$keyfile")){&header; &error_message('datafile error/system','data file access failed.');} print OUT @keyword; close OUT; $htmlfile="$keydir$maxno.html"; if(!open(OUT,">$htmlfile")){&header; &error_message('datafile error/system','data file access failed.');} print OUT << "EOM"; $guild_name Keyword-[ $title ]
$guild_name Keyword
$title ($comment)

$body

・このキーワードが使われた日記

Script by senobeya.com
FF11 Member Registration System $version
EOM close OUT; chmod 0666,$htmlfile; &reload_header; print "
キーワード登録完了
"; print "新規キーワード[ $title ]を追加しました。自動的にトップページに戻ります
"; } } # #登録ユーザーログイン # sub login { if(!open(IN,"$datafile")){&header; &error_message('datafile error/system','data file access failed.');} @all=; close IN; $match=""; foreach $i(@all){ ($r_no,$r_name,$r_pass,$r_dummy)=split(/\t/,$i); if($r_name eq $name && $pass eq $r_pass){ $match=$i; } } if($match eq ""){&header; &error_message('id/pass error','access failed.');} if ($mode eq "login"){ &set_cookie; &header; &login_enter; } elsif($mode eq "menu"){ &set_cookie; &header; &login_menu; } elsif($mode eq "modify"){ &login_modify; } else { &set_cookie; &header; &login_enter; } } # #新規登録 # sub new_regist{ if(($gpass ne $reg_pass && $reg_mode==0)){&error_message('illegal login','password is not correct.');} if($mode eq "regist"){ &new_regist_regist; } else { &new_regist_normal; } } # #リスト表示 # sub list{ if(!open(IN,"$datafile")){&error_message('datafile error578','data file access failed.');} @all=; close IN; if($sort ne "" && $limit != 8){ &sort_table; } print "
"; $vmode="Mode: $modelist[$limit]"; if($limit==1){ if($level==1){ $vmode="$vmode / Level"; } else { $vmode="$vmode / Job"; } } print ""; &make_salt; #メニュー表示 if($pulldown_menu == 1){ print ""; print ""; } else { print ""; } #メニュー表示おわり print <<"EOM";
$guild_name Member List$vmode
$menux[3]$menux[1] / "; print "$menux[2] / "; print ""; print "\n"; if($bbspage){print " / $menux[0]";} print "
$menux[3]$menux[1] / "; print "$menux[2] / "; for($j=0;$j<$#menu+1;$j++){ if($tablelevel[$j] eq ""){ $tablelevel[$j]=$level; } print "$menu[$j] "; } if($bbspage){print " / $menux[0]";} print "
Login : name pass EOM if(!$diaryallow){ print ""; } if($key_avail){ print ""; } if($mpoint ==1){ print ""; } if($mes_avail){ #新規メッセージチェック print "
"; if (-e "$mesdir$c_name.cgi") { if(!open(IN,"$mesdir$c_name.cgi")){&error_message('datafile error490','data file access failed.');} @mes=; close IN; $k=0; for $i(@mes){ ($j,$dummy)=split(/\t/,$i); $k=$k+$j; } if($k>0){print "$k 件の新しいメッセージがあります。";} } print "Message :"; } print <<"EOM";
EOM if($reg_mode==0){print "";} print ""; print "

"; if(!open(IN,"message.tbl")){$osirase="no"} else { $osirase=; $osirase =~ s/\n//g; $osirase =~ s/\r//g; $osirasebody=; close IN; if($osirase ne "no" && $osirase ne ""){ print "
$osirase
$osirasebody
"; } } $members=$#all+1; if($language ne "English"){ print "\n"; } else { print "
現在の登録メンバー数:$members
\n"; } print "
Now Registed member:$members people"; if($level==1){ print ""; for($i=0;$i<$#color+1;$i++){ $ls=$i*10; $le=$i*10+9; print ""; } print ""; } else { print ""; } print "
 Lv$ls-$le   
 main job    support job 
"; require('table.pl'); $call=$tablelist[$limit]; if($c_match){&$call;} else { print 'No cookie or not match password.
Login first."';} print <<"EOM";
EOM } # #使い方表示 # sub faq { if($reg_mode == 0){ $message="あらかじめ設定されているマスターパスワードを下のフォームに入力し、"; } print <<"EOM";
使い方
メンバーの新規登録
 メンバーの新規登録には$message新規登録ボタンを押します。
 新規登録モードに入りますので、次に新規メンバーの名前、パスワード他のデータを入れる画面が出てくるので、  必要事項を入力してください。
 ここで入れるパスワードは、そのメンバー専用のパスワードとなります。

メンバーのデータ修正
 メンバーは登録したnameとパスワードを入れることでそのデータを随時修正することができます。
 必要なデータを入力して、修正ボタンを押してください。

メンバーの削除
 マスターモードを用いて行います。

閲覧方法
タイトル右上に表\示モードが出ています。

表\のモード
Simple:表\示内容を制限したもので表\示します。
Job /Job:ジョブ情報の表\示。メイン・サポートのジョブの背景色が変わります
Job /Level:ジョブ情報の表\示。レベルによって色分けされた背景色となります
Production:生産スキルに関する情報を表\示します
Status:その他さまざまな情報を表\示します
Full:一覧性の高い表\で登録内容を表\示します。
Full2:プロフィールを除く登録内容を表\示します。
Profile:プロフィールと日記の閲覧モードです

プロフィールと日記
名前をクリックするとプロフィールを閲覧することができます。日記アイコン()が出ている場合は、その人の日記も閲覧できます。
UPアイコン()が出ている場合は24時間以内に日記が更新された事を示します。
EOM if($diaryres ==1){print "日記の下にコメントをつけることが可能\になっています。
";} print "
[登録システム入り口][使い方][ホームページへ戻る]
"; } # #汎用サブルーチン。使いまわし&パクり。そしてだんだんと汎用でなくなってくるという様子 # sub form_read { #if ($ENV{'REQUEST_METHOD'} eq "POST") { @upfiles = (); if ($ENV{'REQUEST_METHOD'} eq "POST" && $ENV{'CONTENT_TYPE'} =~ m#^multipart/form-data#) { $buffer1 = ""; $qs = ""; $buffer2 = $ENV{'CONTENT_LENGTH'}; binmode(STDIN); while ($buffer2) { $buffer2 -= sysread(STDIN, $buffer1, $buffer2); $qs .= $buffer1; } $delimita = $1 if $qs =~ /^([^\r\n]*)/; foreach (split(/$delimita/,$qs)){ if ($_ =~ / name=\"(\w*)\"\r\n/){ $key = $1; } elsif ($_ =~ / name=\"(\w*)\"; filename=\"(.+)\"\r\n/i){ ($key,$upfile)=($1,$2); $upct = $1 if $_ =~ /Content-Type: ?(.*)\r\n/i; }else{ next; } $value = (split(/\r\n\r\n/,$_,2))[1]; $value =~ s/[\r\n]+$//g; # $value =~ s/\r\n$//g; if ($key =~ /^upfile[1-9]*/ && $upfile ne ""){ push(@upfiles, $upfile); $upfile{$upfile} = $value; $upct{$upfile} = lc($upct); if($key eq "upfile"){ $in{'upfile'}=$value; $in{'upfilename'}=$upfile; $in{'upct'}=lc($upct); } } else { &jcode::convert(\$value,'sjis'); $value =~ s//>/g; $value =~ s/\t//g; $value =~ s/\r\n/
/g; $value =~ s/\n/
/g; $value =~ s/\r/
/g; # $value =~ s/\,//g; # $value =~ s/'/’/g; $FORM{$key} = $value; } } } else { #$buffer = $ENV{'QUERY_STRING'}; if($ENV{'REQUEST_METHOD'} eq 'GET' || $ENV{'REQUEST_METHOD'} eq 'HEAD') { $buffer = $ENV{'QUERY_STRING'}; } elsif ($ENV{'REQUEST_METHOD'} eq 'POST') { read(STDIN, $buffer, $ENV{'CONTENT_LENGTH'}); } @pairs = split(/&/,$buffer); foreach $pair (@pairs) { ($name, $value) = split(/=/, $pair); $value =~ tr/+/ /; $value =~ s/%([a-fA-F0-9][a-fA-F0-9])/pack("C", hex($1))/eg; &jcode'convert(*value,'sjis'); $value =~ s//>/g; $value =~ s/\n//g; $value =~ s/\t//g; $value =~ s/\r/
/g; # $value =~ s/\,//g; $FORM{$name} = $value; } } $no=$FORM{'no'}; $name=$FORM{'name'}; $name2=$FORM{'name2'}; $pass=$FORM{'pass'}; $gpass=$FORM{'gpass'}; $function=$FORM{'function'}; $mode=$FORM{'mode'}; $all=$FORM{'all'}; $anon=$FORM{'anon'}; $race=$FORM{'race'}; $relm=$FORM{'relm'}; $mainjob=$FORM{'mainjob'}; $supportjob=$FORM{'supportjob'}; $lev[0]=$FORM{'lev0'}; $lev[1]=$FORM{'lev1'}; $lev[2]=$FORM{'lev2'}; $lev[3]=$FORM{'lev3'}; $lev[4]=$FORM{'lev4'}; $lev[5]=$FORM{'lev5'}; $lev[6]=$FORM{'lev6'}; $lev[7]=$FORM{'lev7'}; $lev[8]=$FORM{'lev8'}; $lev[9]=$FORM{'lev9'}; $lev[10]=$FORM{'lev10'}; $lev[11]=$FORM{'lev11'}; $lev[12]=$FORM{'lev12'}; $lev[13]=$FORM{'lev13'}; $lev[14]=$FORM{'lev14'}; $lev[15]=$FORM{'lev15'}; $lev[15]=~ s/\n//g; #ジョブ追加対策(応急措置) $lev[16]=~ s/\n//g; #ジョブ追加対策(応急措置) $lev[16]=$FORM{'lev16'}; $lev[17]=$FORM{'lev17'}; $lev[18]=$FORM{'lev18'}; $lev[19]=$FORM{'lev19'}; $prod[0]="$FORM{'prod0'}"; $prod[1]="$FORM{'prod1'}"; $prod[2]="$FORM{'prod2'}"; $prod[3]="$FORM{'prod3'}"; $prod[4]="$FORM{'prod4'}"; $prod[5]="$FORM{'prod5'}"; $prod[6]="$FORM{'prod6'}"; $prod[7]="$FORM{'prod7'}"; $prod[8]="$FORM{'prod8'}"; $prod[9]="$FORM{'prod9'}"; $prod[14]=$FORM{'profimage'}; #プロフ画像に転用 $prod[11]="$FORM{'prod11'}"; #カスタムフィールドデータ $prod[12]="$FORM{'prod12'}"; #メリポデータ(表示用) $prod[13]="$FORM{'prod13'}"; #生メリポデータ $prod[12] =~ s/<//g; for ($j=1;$j<$#custom_field+1;$j++){ $custom[$j]=$FORM{"custom$j"}; $custom[$j] =~ s/,/‚/g; } #残るはprod[10] #prod[11]はカスタムフィールド、prod[12]とprod[13]はメリポに使用。 #&conv_zenkaku; $ktai=$FORM{'ktai'}; for ($j=0;$j<10;$j++){ $prod_r[$j]=$FORM{"prod_r$j"}; } $etc[1]=join(",", @prod_r); for ($j=0;$j<$#skilllist+1;$j++){ $skill[$j]=$FORM{"skill$j"}; } $etc[2]=join(",", @skill); if($ktai eq "on" && $function ne "mission"){ $prod[15]="$FORM{'prod15'}"; } else { for ($j=0;$j<$#mlist+2;$j++){ $mission[$j]=$FORM{"mission$j"}; } $FORM{"assault0"}=sprintf("%x",$FORM{"assault0"}); for($j=0;$j<$#aslist+1;$j++){ $mission[16]=$mission[16].$FORM{"assault$j"}; } $prod[15]=join(",", @mission); #進行度フラグに転用 } $ietc=$FORM{'ietc'}; $etc1=$FORM{'etc1'}; $mrank=$FORM{'mrank'}; $prof=$FORM{'prof'}; $handle=$FORM{'handle'}; $polhn=$FORM{'polhn'}; $mail=$FORM{'mail'}; $home=$FORM{'home'}; $comment2=$FORM{'comment2'}; $point=$FORM{'point'}; $class=$FORM{'class'}; $comment=$FORM{'comment'}; $sort=$FORM{'sort'}; $level=$FORM{'level'}; $limit=$FORM{'limit'}; $body=$FORM{'body'}; $body2=$FORM{'body2'}; $title=$FORM{'title'}; $page=$FORM{'page'}; $etc[0]=$FORM{'ftype'}; $imgdel=$FORM{'imgdel'}; if($page eq ""){$page=1;} if($level eq "" ){$level=$level_mode;} if($limit eq ""){$limit=$limit_table;} #ソート条件未指定時標準ソート条件設定 if( $default_sort != 0 && $limit==13 && $sort eq "" && $function eq ""){ $mode=$default_mode; $sort=$default_sort; $function=$default_function; $no=$default_no; } if( $default_sort==16 && $sort eq "" && $function eq ""){ $mode=$default_mode; $sort=$default_sort; } $ln=$FORM{'ln'}; if($ln ne ""){$language=$ln;} ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime(time); @wday_array = ('日','月','火','水','木','金','土'); $mon++; $year=$year-100; if($year<10){ $year="0$year"; } if($mon<10){ $mon="0$mon"; } if($mday<10){ $mday="0$mday"; } if($hour<10){ $hour="0$hour"; } if($min<10){ $min="0$min"; } $rsstime="20$year-$mon-$mday"."T$hour:$min:00+09:00"; $timenow="$year/$mon/$mday/$hour$min"; $today = "$mon/$mday"; $today2= "$year/$mon/$mday $hour:$min"; $rh = $ENV{'REMOTE_HOST'}; $addr = $ENV{'REMOTE_ADDR'}; } ################# #-- 以下スキル表示機能で追加した部分 # ============================================================================= # # スキルキャップ計算 # ============================================================================= # # スキルキャップを計算する # 引数0 ジョブ # 引数1 スキル # 引数2 レベル # $skill_rank <- スキルランク # $skill_cap <- スキルキャップ # add by Pensil # 2003.03.02 Modified by Hally sub expr_skillcap { # ランクをチェック $skill_rank = substr( $skillrank[$_[0]], ($_[1]) * 2, 1 ); $skill_detail = substr( $skillrank[$_[0]], ($_[1]) * 2, 2 ); if ($skill_rank eq "_") { $skill_cap = 0; } else { # -50 if ($_[2] < 51) { if ($skill_rank eq "A") { $skill_cap = ($_[2] - 1) * 3.0 + 6; } if ($skill_rank eq "B") { $skill_cap = ($_[2] - 1) * 2.9 + 5; } if ($skill_rank eq "C") { $skill_cap = ($_[2] - 1) * 2.8 + 5; } if ($skill_rank eq "D") { $skill_cap = ($_[2] - 1) * 2.7 + 4; } if ($skill_rank eq "E") { $skill_cap = ($_[2] - 1) * 2.5 + 4; } if ($skill_rank eq "F") { $skill_cap = ($_[2] - 1) * 2.3 + 4; } # -60 } elsif ($_[2] < 61) { if ($skill_rank eq "A") { $skill_cap = ($_[2] - 50) * 5.0 + 153; } if ($skill_rank eq "B") { $skill_cap = ($_[2] - 50) * 4.9 + 147; } if ($skill_rank eq "C") { $skill_cap = ($_[2] - 50) * 4.8 + 142; } if ($skill_rank eq "D") { $skill_cap = ($_[2] - 50) * 4.7 + 136; } if ($skill_rank eq "E") { $skill_cap = ($_[2] - 50) * 4.5 + 126; } if ($skill_rank eq "F") { $skill_cap = ($_[2] - 50) * 4.3 + 116; } # -70 } elsif ($_[2] < 71) { if ($skill_detail eq "A+") { $skill_cap = ($_[2] - 60) * 4.85 + 203; } if ($skill_detail eq "A ") { $skill_cap = ($_[2] - 60) * 4.10 + 203; } if ($skill_detail eq "B+") { $skill_cap = ($_[2] - 60) * 3.70 + 196; } if ($skill_detail eq "B ") { $skill_cap = ($_[2] - 60) * 3.23 + 196; } if ($skill_detail eq "B-") { $skill_cap = ($_[2] - 60) * 2.70 + 196; } if ($skill_detail eq "C+") { $skill_cap = ($_[2] - 60) * 2.50 + 190; } if ($skill_detail eq "C ") { $skill_cap = ($_[2] - 60) * 2.25 + 190; } if ($skill_detail eq "C-") { $skill_cap = ($_[2] - 60) * 2.00 + 190; } if ($skill_rank eq "D" ) { $skill_cap = ($_[2] - 60) * 1.85 + 183; } if ($skill_rank eq "E" ) { $skill_cap = ($_[2] - 60) * 1.95 + 171; } if ($skill_rank eq "F" ) { $skill_cap = ($_[2] - 60) * 2.00 + 159; } # -73 } elsif ($_[2] < 74) { if ($skill_detail eq "A+") { $skill_cap = ($_[2] - 70) * 5.00 + 251; } if ($skill_detail eq "A ") { $skill_cap = ($_[2] - 70) * 5.00 + 244; } if ($skill_detail eq "B+") { $skill_cap = ($_[2] - 70) * 4.34 + 233; } if ($skill_detail eq "B ") { $skill_cap = ($_[2] - 70) * 4.00 + 228; } if ($skill_detail eq "B-") { $skill_cap = ($_[2] - 70) * 3.00 + 223; } if ($skill_detail eq "C+") { $skill_cap = ($_[2] - 70) * 3.00 + 215; } if ($skill_detail eq "C ") { $skill_cap = ($_[2] - 70) * 2.50 + 212; } if ($skill_detail eq "C-") { $skill_cap = ($_[2] - 70) * 2.00 + 210; } if ($skill_rank eq "D" ) { $skill_cap = ($_[2] - 70) * 2.00 + 201; } if ($skill_rank eq "E" ) { $skill_cap = ($_[2] - 70) * 2.00 + 190; } if ($skill_rank eq "F" ) { $skill_cap = ($_[2] - 70) * 2.00 + 179; } # -75 } elsif ($_[2] < 76) { if ($skill_detail eq "A+") { $skill_cap = ($_[2] - 73) * 5.00 + 266; } if ($skill_detail eq "A ") { $skill_cap = ($_[2] - 73) * 5.00 + 259; } if ($skill_detail eq "B+") { $skill_cap = ($_[2] - 73) * 5.00 + 246; } if ($skill_detail eq "B ") { $skill_cap = ($_[2] - 73) * 5.00 + 240; } if ($skill_detail eq "B-") { $skill_cap = ($_[2] - 73) * 4.00 + 232; } if ($skill_detail eq "C+") { $skill_cap = ($_[2] - 73) * 3.00 + 224; } if ($skill_detail eq "C ") { $skill_cap = ($_[2] - 73) * 3.00 + 219; } if ($skill_detail eq "C-") { $skill_cap = ($_[2] - 73) * 2.00 + 216; } if ($skill_rank eq "D" ) { $skill_cap = ($_[2] - 73) * 1.50 + 207; } if ($skill_rank eq "E" ) { $skill_cap = ($_[2] - 73) * 2.00 + 196; } if ($skill_rank eq "F" ) { $skill_cap = ($_[2] - 73) * 2.00 + 185; } } $skill_cap = int($skill_cap); } $_ = $skill_cap; #print "($_[0],$_[1],$_[2],$skill_rank,$skill_detail,$skill_cap)"; } #必要経験値を計算する # 引数0 レベル # thx for えるさん sub expr_needexp { local($lv) = @_; if ( $lv < 1 ) { $_ = 0; } elsif ( $lv < 8 ) { $_ = $lv * 250 + 250; } elsif ( $lv < 23 ) { $_ = $lv * 200 + 600; } elsif ( $lv < 51 ) { $_ = $lv * 100 + 2800; } elsif ( $lv < 62 ) { $_ = ($lv - 51) * 1200 + 8000; } elsif ( $lv < 70 ) { $_ = ($lv - 61) * 1500 + 20000; } else { $_ = ($lv - 69) * 2000 + 32000; } } #これまでの獲得経験値を計算する # 引数0 レベル # thx for えるさん sub expr_exp { $lv = $_[0]; if ($lv < 2) { $_ = 0; return; } $lv = $lv -1; if ( $lv < 8 ) { $_ = 125.0 * ($lv * $lv + $lv * 3); } elsif ( $lv < 23 ) { $_ = 100.0 * $lv * $lv + 700.0 * $lv - 1050.0; } elsif ( $lv < 51 ) { $_ = 50.0 * $lv * $lv + 2850.0 * $lv - 24150.0; } elsif ( $lv < 62 ) { $_ = 600.0 * $lv * $lv - 52600.0 * $lv + 1373350.0; } elsif ( $lv < 70 ) { $_ = 750.0 * $lv * $lv - 70750.0 * $lv + 1922350.0; } else { $_ = 1000.0 * $lv * $lv - 105000.0 * $lv + 3095350.0; } } sub writehist { local($histtype,$histdata) = @_; @outhist = (); push(@outhist, "$histtype\t$timenow\t$ENV{REMOTE_ADDR}\t$histdata"); if(!open(OUT,">>$historyfile")){&header; &error_message('datafile error726','history file access failed.');} print OUT @outhist; close OUT; } #-- スキル表示機能で追加した部分ここまで ################# sub header { print "Content-type: text/html\n\n"; print "$topic\n"; if($language ne "English"){ print ''; } else { print ''; } print "\n"; if($bgimg eq ""){ print "\n\n"; } else { print "\n\n"; } if(!open(IN,"header.html")){$header=""} else { $headerbody=; close IN; print $headerbody; } } sub reload_header { print "Content-type: text/html\n\n"; print "$topic\n"; if($language ne "English"){ print ''; } else { print ''; } print ""; print '"; print "\n\n"; } sub reload_header2 { print "Content-type: text/html\n\n"; print "$topic\n"; if($language ne "English"){ print ''; } else { print ''; } print ""; print '"; print "\n\n"; } sub footer { print "
"; if($language ne "English"){ print "
Script by senobeya.com
\n"; } else { print "\n"; } print "
FF11 Member Registration System $version
\n"; if($iconurl ne ""){ print "
Icon by $iconhp
\n"; } print "
Copyright (C) 2002- SQUARE ENIX CO., LTD. All Rights Reserved.
\n"; print ""; } sub error_message { print "

$_[0]

\n"; print "

$_[1]

\n"; if($language ne "English"){ print "ブラウザの[戻る]ボタンを押して前の画面に移動してください.

\n"; } else { print "Push [back]button to move former page.

\n"; } &footer; exit; } sub get_cookie { @pairs = split(/\;/,$ENV{'HTTP_COOKIE'}); foreach $pair (@pairs) { local($name, $value) = split(/\=/, $pair); $name =~ s/ //g; $DUMMY{$name} = $value; } @pairs = split(/\,/,$DUMMY{'BODD'}); foreach $pair (@pairs) { local($name, $value) = split(/\:/, $pair); $COOKIE{$name} = $value; } $c_name = $COOKIE{'name'}; $c_pass = $COOKIE{'pass'}; } sub set_cookie { ($secg,$ming,$hourg,$mdayg,$mong,$yearg,$wdayg,$ydayg,$isdstg) = gmtime(time + 60*24*60*60); $yearg += 1900; if ($secg < 10) { $secg = "0$secg"; } if ($ming < 10) { $ming = "0$ming"; } if ($hourg < 10) { $hourg = "0$hourg"; } if ($mdayg < 10) { $mdayg = "0$mdayg"; } $mong = ('Jan','Feb','Mar','Apr','May','Jun','Jul','Aug','Sep', 'Oct','Nov','Dec') [$mong]; $youbi = ('Sunday','Monday','Tuesday','Wednesday','Thursday', 'Friday','Saturday') [$wdayg]; $date_gmt = "$youbi, $mdayg\-$mong\-$yearg $hourg:$ming:$secg GMT"; $ENV{'TZ'} = "JST-9"; ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime(time); @wday_array = ('日','月','火','水','木','金','土'); $mon++; $year=$year-100; if($year<10){ $year="0$year"; } if($mon<10){ $mon="0$mon"; } if($mday<10){ $mday="0$mday"; } if($hour<10){ $hour="0$hour"; } if($min<10){ $min="0$min"; } $timenow="$year/$mon/$mday/$hour$min"; $cook="name\:$name\,pass\:$pass"; print "Set-Cookie: BODD=$cook; expires=$date_gmt\n"; } sub sort_table { $sort=$sort/1; @temp=(); foreach $i (@all){ ($t[0],$t[1],$t[2],$t[3],$t[4],$t[5],$t[6],$t[7],$t[8],$t[9],$t[10],$t[11],$t[12],$t[13],$t[14],$t[15],$t[16],$t[17],$t[18],$t[19],$t[20],$t[21],$t[22],$t[23],$t[24],$t[25],$t[26],$t[27],$t[28],$t[29],$t[30],$t[31],$t[32],$t[33],$t[34],$t[35],$t[36],$t[37],$t[38],$t[39],$t[40],$t[41],$t[42],$t[43],$t[44],$t[45],$t[46],$t[47],$t[48],$t[49],$t[50],$t[51],$t[52],$t[53],$t[54],$t[55],$t[56],$t[57])=split(/\t/,$i); #for($j=38;$j<$job_max+38;$j++){ # if($t[$j]<10){$t[$j]="0$t[$j]";} #} #for($j=22;$j<$prod_max+22;$j++){ # if($t[$j]<10){$t[$j]="0$t[$j]";} #} for($j=38;$j<$job_max+38;$j++){ $t[$j]=sprintf("%3d",$t[$j]); } for($j=22;$j<$prod_max+22;$j++){ $t[$j]=sprintf("%3d",$t[$j]); } #ミッションソート用 sort=37 function=[ミッション種別] page=アサルト用キー if($sort ==37){ @mission = split(/,/,$t[37]); if($function == 16){ @assault = split (//,$mission[16]); $assault[0]=hex($assault[0]); $missionkey=sprintf("%2d",$assault[$page]); } else { $missionkey=sprintf("%2d",$mission[$function]); } $t[37]="$missionkey"."T"."$t[37]"; } #カスタムフィールドソート用 sort=33 function番号、 ソートモード=no if($sort ==33){ @custom = split(/,/,$t[33]); if($no==1){ $missionkey=sprintf("%10d",$custom[$function]); } else { $missionkey=sprintf("%-10s",$custom[$function]); } $t[33]="$missionkey"."_T_"."$t[33]"; } $t_temp=$t[0]; $t[0]=$t[$sort]; $t[$sort]=$t_temp; push(@temp,"$t[0]\t$t[1]\t$t[2]\t$t[3]\t$t[4]\t$t[5]\t$t[6]\t$t[7]\t$t[8]\t$t[9]\t$t[10]\t$t[11]\t$t[12]\t$t[13]\t$t[14]\t$t[15]\t$t[16]\t$t[17]\t$t[18]\t$t[19]\t$t[20]\t$t[21]\t$t[22]\t$t[23]\t$t[24]\t$t[25]\t$t[26]\t$t[27]\t$t[28]\t$t[29]\t$t[30]\t$t[31]\t$t[32]\t$t[33]\t$t[34]\t$t[35]\t$t[36]\t$t[37]\t$t[38]\t$t[39]\t$t[40]\t$t[41]\t$t[42]\t$t[43]\t$t[44]\t$t[45]\t$t[46]\t$t[47]\t$t[48]\t$t[49]\t$t[50]\t$t[51]\t$t[52]\t$t[53]\t$t[54]\t$t[55]\t$t[56]\t$t[57]\t\n"); } @temp=sort(@temp); if($mode eq "r"){ @temp=reverse(@temp); } @all=(); foreach $i (@temp){ ($t[0],$t[1],$t[2],$t[3],$t[4],$t[5],$t[6],$t[7],$t[8],$t[9],$t[10],$t[11],$t[12],$t[13],$t[14],$t[15],$t[16],$t[17],$t[18],$t[19],$t[20],$t[21],$t[22],$t[23],$t[24],$t[25],$t[26],$t[27],$t[28],$t[29],$t[30],$t[31],$t[32],$t[33],$t[34],$t[35],$t[36],$t[37],$t[38],$t[39],$t[40],$t[41],$t[42],$t[43],$t[44],$t[45],$t[46],$t[47],$t[48],$t[49],$t[50],$t[51],$t[52],$t[53],$t[54],$t[55],$t[56],$t[57])=split(/\t/,$i); #ミッションソート用 sort=37 function=[ミッション種別] if($sort ==37){ ($dummy,$t[0]) = split(/T/,$t[0]); } #カスタムフィールドソート用 sort=33 function=[項目番号] if($sort ==33){ ($dummy,$t[0]) = split(/_T_/,$t[0]); } $t_temp=$t[0]; $t[0]=$t[$sort]; $t[$sort]=$t_temp; for($j=38;$j<$job_max+38;$j++){ $t[$j]=$t[$j]/1; } for($j=22;$j<$prod_max+22;$j++){ $t[$j]=$t[$j]/1; } push(@all,"$t[0]\t$t[1]\t$t[2]\t$t[3]\t$t[4]\t$t[5]\t$t[6]\t$t[7]\t$t[8]\t$t[9]\t$t[10]\t$t[11]\t$t[12]\t$t[13]\t$t[14]\t$t[15]\t$t[16]\t$t[17]\t$t[18]\t$t[19]\t$t[20]\t$t[21]\t$t[22]\t$t[23]\t$t[24]\t$t[25]\t$t[26]\t$t[27]\t$t[28]\t$t[29]\t$t[30]\t$t[31]\t$t[32]\t$t[33]\t$t[34]\t$t[35]\t$t[36]\t$t[37]\t$t[38]\t$t[39]\t$t[40]\t$t[41]\t$t[42]\t$t[43]\t$t[44]\t$t[45]\t$t[46]\t$t[47]\t$t[48]\t$t[49]\t$t[50]\t$t[51]\t$t[52]\t$t[53]\t$t[54]\t$t[55]\t$t[56]\t$t[57]\t\n"); } } sub new_regist_regist { if(!open(IN,"$datafile")){&error_message('datafile error1791','data file access failed.');} @all=; close IN; if( !($pass =~ /^[A-Za-z0-9_]+$/) ){ if($language ne "English"){ &error_message('そのパスワードは登録に利用できません。','パスワードは半角英数字で登録してください。'); } else { &error_message('That password is unsuitable.','Password must use a-z and 0-9 letters.'); } } if( !($name =~ /^[A-Za-z0-9_]+$/) ){ if($language ne "English"){ &error_message('その名前は使えません。','名前は半角英数字で登録してください。'); } else { &error_message('That name is unsuitable.','Name must use a-z and 0-9 letters.'); } } if($language ne "English"){ if($mainjob == $supportjob){&error_message('main/job error','メインとサポートは同一のジョブにはできません');} } else { if($mainjob == $supportjob){&error_message('main/job error',"Support job can not set as main's one.");} } $max_no=0; foreach $i (@all){ ($r_no,$r_user,$dummy)=split(/\t/,$i); if($max_no<$r_no){$max_no=$r_no;} if($r_user eq $name){&error_message('already registed',"'$name' has already registed.");} } $no=($max_no+1)/1; if($no<10){$no="0$no";} if($no<100){$no="0$no";} push(@all,"$no\t$name\t$pass\t$anon\t$race\t$relm\t$mainjob\t$supportjob\t$prof\t$handle\t$polhn\t$mail\t$home\t$comment2\t$point\t$class\t$timenow\t$comment\t$mrank\t$etc[0]\t$etc[1]\t$etc[2]\t$prod[0]\t$prod[1]\t$prod[2]\t$prod[3]\t$prod[4]\t$prod[5]\t$prod[6]\t$prod[7]\t$prod[8]\t$prod[9]\t$prod[10]\t$prod[11]\t$prod[12]\t$prod[13]\t$prod[14]\t$prod[15]\t$lev[0]\t$lev[1]\t$lev[2]\t$lev[3]\t$lev[4]\t$lev[5]\t$lev[6]\t$lev[7]\t$lev[8]\t$lev[9]\t$lev[10]\t$lev[11]\t$lev[12]\t$lev[13]\t$lev[14]\t$lev[15]\t$lev[16]\t$lev[17]\t$lev[18]\t$lev[19]\t\n"); &dirlock; if(!open(OUT,">$datafile")){&error_message('datafile error1819','data file access failed.');} print OUT @all; close OUT; rmdir($lockdir); #RSS用履歴ファイル作成 $historybase="NEWREG\t$name\tNewMember\t$rsstime\t$no\t$rh\t\t$addr\t\n"; &add_history; if($language ne "English"){ print "新規メンバー'$name'($no)の登録を完了しました。"; print "


[登録システム入り口][使い方][ホームページへ戻る]
"; } else { print "New Member '$name'($no) is registed."; print "
[Entrance][usage][Back to Homepage]
"; } } sub new_regist_normal { if($language ne "English"){ print "
新規メンバー登録
\n新規メンバーを登録します。必要事項を入力してください。\n"; } else { print "
New Member Regist
\nFor registration, fill your information.\n"; } print <<"EOM"; EOM if($class_edit){ print "\n"; } else { print ""; } print <<"EOM"; EOM print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; for($i=0;$i<$job_max;$i++){ print "\n"; } for($i=0;$i<$prod_max;$i++){ print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; $comment2 =~ s/
/\r/g; print "\n"; if($language ne "English"){ print "\n
$field[0]
$field[1]
$field[2]
$field[3]
$field[4]
$field[5] ($field[18])
$field[6]
$field[7]
$field[8]
$joblist[$i]
$prodlist[$i]"; print "
$field[9]
$field[10]
$field[11]

$field[12]
$field[13]
$field[14]
$field[15]
$field[16]
$field[17]
"; print "
[登録システム入り口][使い方][ホームページへ戻る]
"; } else { print "\n"; print "
[Entrance][Usage][Back to homepage]
"; } } sub custom_field{ #カスタムフィールド if(!open(IN,"$datafile")){&header; &error_message('datafile error/system','data file access failed.');} @all=; close IN; $match=""; foreach $i(@all){ ($r_no,$r_name,$r_pass,$r_dummy)=split(/\t/,$i); if($r_name eq $name && $pass eq $r_pass){ $match=$i; } } if($match eq ""){&header; &error_message('id/pass error','access failed.');} $match =~ s/"/"/g; #オペレーター入力 if($mode eq "operatorlogin"){ &header; print "
$custom_field[0]の修正 オペレーターモード
"; print "MemberList Top
"; print "
"; print "
"; for($j=1;$j<$#custom_field+1;$j++){ if($custom_control[$j] eq $name){ print "\n"; $count=0; foreach $i(@all){ ($no,$rname,$dummy,$anon,$race,$relm,$mainjob,$supportjob,$prof,$handle,$polhn,$mail,$home,$comment2,$point,$class,$time,$comment,$mrank,$etc[0],$etc[1],$etc[2],$prod[0],$prod[1],$prod[2],$prod[3],$prod[4],$prod[5],$prod[6],$prod[7],$prod[8],$prod[9],$prod[10],$prod[11],$dummy)=split(/\t/,$i); @custom=split(/,/,$prod[11]); if($custom_pulldown[$j] == 1){ print ""; } else { print ""; } $count++; } print ""; print "
$rname
$rname
加算対象
\n"; } else { print "\n"; } } #積算フィールド指定はここですることに print "
"; } elsif($mode eq "operatormodify"){ &dirlock; @out=(); $count=0; foreach $i(@all){ ($no,$rname,$rpass,$anon,$race,$relm,$mainjob,$supportjob,$prof,$handle,$polhn,$mail,$home,$comment2,$point,$class,$time,$comment,$mrank,$etc[0],$etc[1],$etc[2],$prod[0],$prod[1],$prod[2],$prod[3],$prod[4],$prod[5],$prod[6],$prod[7],$prod[8],$prod[9],$prod[10],$prod[11],$prod[12],$prod[13],$prod[14],$prod[15],$lev[0],$lev[1],$lev[2],$lev[3],$lev[4],$lev[5],$lev[6],$lev[7],$lev[8],$lev[9],$lev[10],$lev[11],$lev[12],$lev[13],$lev[14],$lev[15],$lev[16],$lev[17],$lev[18],$lev[19])=split(/\t/,$i); @custom=split(/,/,$prod[11]); for($j=1;$j<$#custom_field+1;$j++){ if($custom_control[$j] eq $name){ $custom[$j]=$FORM{"custom$count"."_$j"}; if($FORM{"custom0"} != 0){ $custom[$FORM{"custom0"}] += $FORM{"custom$count"."_$j"}; } } } $prod[11]=join(",", @custom); $prod[12] =~ s/"/"/g; $newdat="$no\t$rname\t$rpass\t$anon\t$race\t$relm\t$mainjob\t$supportjob\t$prof\t$handle\t$polhn\t$mail\t$home\t$comment2\t$point\t$class\t$time\t$comment\t$mrank\t$etc[0]\t$etc[1]\t$etc[2]\t$prod[0]\t$prod[1]\t$prod[2]\t$prod[3]\t$prod[4]\t$prod[5]\t$prod[6]\t$prod[7]\t$prod[8]\t$prod[9]\t$prod[10]\t$prod[11]\t$prod[12]\t$prod[13]\t$prod[14]\t$prod[15]\t$lev[0]\t$lev[1]\t$lev[2]\t$lev[3]\t$lev[4]\t$lev[5]\t$lev[6]\t$lev[7]\t$lev[8]\t$lev[9]\t$lev[10]\t$lev[11]\t$lev[12]\t$lev[13]\t$lev[14]\t$lev[15]\t$lev[16]\t$lev[17]\t$lev[18]\t$lev[19]\t\n"; push(@out,$newdat); $count++; } if(!open(OUT,">$datafile")){&header; &error_message('datafile error1560','data file access failed.');} print OUT @out; close OUT; rmdir($lockdir); #custom_field[0]のcustom0名称変更処理 #編集項目更新処理 for($i=1;$i<$#custom_field+1;$i++){ $custom_field[$i]=$FORM{"customf$i"}; } @list=( 'custom_field', ); &dirlock; if(!open(IN,"setup.cgi")){&error_message('config file error','data file access failed.');} @all=; close IN; foreach $item(@list){ $match=0; for($i=0;$i<$#all+1;$i++){ if($all[$i] =~ /^\@$item=(.*);(.*)/){ $match=1; $temp=$2; $arr="\@$item=("; for($j=0;$j<$#$item+1;$j++){ if ($$item[$j] =~ /.*\\$/){ $$item[$j].="\\"; } $$item[$j] =~ s/'//g; $arr.="'$$item[$j]',"; } $arr.=");$2\n"; $all[$i]=$arr; } } if($match==0){ $arr="\@$item=("; for($j=0;$j<$#$item+1;$j++){ if ($$item[$j] =~ /.*\\$/){ $$item[$j].="\\"; } $$item[$j] =~ s/'//g; $arr.="'$$item[$j]',"; } $arr.=");\n\n"; push(@all,$arr); } } @out=@all; &check_out; if(!open(OUT,">setup.cgi")){&error_message('config file error','data file access failed.');} print OUT @out; close OUT; rmdir($lockdir); &reload_header; print "
オペレーターによる$custom_field[0]の修正を行いました。
"; print "自動的に戻ります。
"; print "MemberList Top
"; } elsif($mode eq "modify"){ #書き込み ($no,$name,$pass,$anon,$race,$relm,$mainjob,$supportjob,$prof,$handle,$polhn,$mail,$home,$comment2,$point,$class,$time,$comment,$mrank,$etc[0],$etc[1],$etc[2],$prod[0],$prod[1],$prod[2],$prod[3],$prod[4],$prod[5],$prod[6],$prod[7],$prod[8],$prod[9],$prod[10],$dummy,$prod[12],$prod[13],$prod[14],$prod[15],$lev[0],$lev[1],$lev[2],$lev[3],$lev[4],$lev[5],$lev[6],$lev[7],$lev[8],$lev[9],$lev[10],$lev[11],$lev[12],$lev[13],$lev[14],$lev[15],$lev[16],$lev[17],$lev[18],$lev[19])=split(/\t/,$match); $prod[11]=join(",", @custom); &dirlock; if(!open(IN,"$datafile")){&error_message('datafile error612i','data file access failed.');} @all=; close IN; @out=(); foreach $i(@all){ ($r_no,$r_name,$r_pass,$r_dummy)=split(/\t/,$i); if($r_name eq $name && $pass eq $r_pass){ $pastdat=$i; $prod[12] =~ s/"/"/g; $newdat="$r_no\t$name\t$pass\t$anon\t$race\t$relm\t$mainjob\t$supportjob\t$prof\t$handle\t$polhn\t$mail\t$home\t$comment2\t$point\t$class\t$timenow\t$comment\t$mrank\t$etc[0]\t$etc[1]\t$etc[2]\t$prod[0]\t$prod[1]\t$prod[2]\t$prod[3]\t$prod[4]\t$prod[5]\t$prod[6]\t$prod[7]\t$prod[8]\t$prod[9]\t$prod[10]\t$prod[11]\t$prod[12]\t$prod[13]\t$prod[14]\t$prod[15]\t$lev[0]\t$lev[1]\t$lev[2]\t$lev[3]\t$lev[4]\t$lev[5]\t$lev[6]\t$lev[7]\t$lev[8]\t$lev[9]\t$lev[10]\t$lev[11]\t$lev[12]\t$lev[13]\t$lev[14]\t$lev[15]\t$lev[16]\t$lev[17]\t$lev[18]\t$lev[19]\t\n"; push(@out,$newdat); } else { push(@out,$i); } } if(!open(OUT,">$datafile")){&header; &error_message('datafile error1560','data file access failed.');} print OUT @out; close OUT; rmdir($lockdir); #RSS用履歴ファイル作成 &compare_history; $historybase="CUSTED\t$name\t$name profile modify\t$rsstime\t$no\t$message\t$rh\t$addr\t\n"; &add_history; &reload_header; print "
$custom_field[0]を修正しました。
"; print "MemberList Top
自動的に戻ります。"; } else { &header; #入力リスト表示 ($no,$name,$pass,$anon,$race,$relm,$mainjob,$supportjob,$prof,$handle,$polhn,$mail,$home,$comment2,$point,$class,$time,$comment,$mrank,$etc[0],$etc[1],$etc[2],$prod[0],$prod[1],$prod[2],$prod[3],$prod[4],$prod[5],$prod[6],$prod[7],$prod[8],$prod[9],$prod[10],$prod[11],$prod[12],$prod[13],$prod[14],$prod[15],$lev[0],$lev[1],$lev[2],$lev[3],$lev[4],$lev[5],$lev[6],$lev[7],$lev[8],$lev[9],$lev[10],$lev[11],$lev[12],$lev[13],$lev[14],$lev[15],$lev[16],$lev[17],$lev[18],$lev[19])=split(/\t/,$match); @custom=split(/,/,$prod[11]); print "
$custom_field[0]を登録修正します。
"; print "MemberList Top
"; print "
"; print "
"; print ""; for ($i=1;$i<$#custom_field+1;$i++){ if($custom_pulldown[$i]==0){ if($custom_control[$i] eq "0"){ print ""; } else { print ""; } } else { if($custom_control[$i] eq "0"){ print ""; } else { print ""; } } } print "
$custom_field[$i]
$custom_field[$i]
"; print "
"; } } ###################### #login_menu ###################### sub login_menu{ if($language ne "English"){ print "
登録データ修正
"; print "MemberList Top
"; print "'$name' さんのデータを修正します。
\n"; } else { print "
Modify Registed information
"; print "MemberList Top
"; print "Modyfying : '$name' information.
\n"; } print "modifying=$all
"; ($no,$name,$pass,$anon,$race,$relm,$mainjob,$supportjob,$prof,$handle,$polhn,$mail,$home,$comment2,$point,$class,$time,$comment,$mrank,$etc[0],$etc[1],$etc[2],$prod[0],$prod[1],$prod[2],$prod[3],$prod[4],$prod[5],$prod[6],$prod[7],$prod[8],$prod[9],$prod[10],$prod[11],$prod[12],$prod[13],$prod[14],$prod[15],$lev[0],$lev[1],$lev[2],$lev[3],$lev[4],$lev[5],$lev[6],$lev[7],$lev[8],$lev[9],$lev[10],$lev[11],$lev[12],$lev[13],$lev[14],$lev[15],$lev[16],$lev[17],$lev[18],$lev[19])=split(/\t/,$match); @prod_r = split(/,/,$etc[1]); @mp=split(/,/,$prod[13]); @mission = split(/,/,$prod[15]); @assault=split( //,$mission[16]); $assault[0]=hex($assault[0]); #################共通フォーム if($language ne "English"){ @templabel=("No. $no : '$name' 修正"); } else { @templabel=("Modifying No. $no : '$name' "); } print "
"; print "$templabel[0]
"; ####################ジョブ・合成スキル if($all eq "m_level"){ print ""; print ""; print "\n"; print "\n"; print ""; print "\n"; print ""; for($i=0;$i<$prod_max;$i++){ print "\n"; } print "
$field[7]
$field[8]

"; for($i=0;$i<10;$i++){ print ""; } print "\n"; for($i=0;$i<10;$i++){ print ""; } print "\n"; for($i=10;$i<$job_max;$i++){ print ""; } print "\n"; for($i=10;$i<$job_max;$i++){ print ""; } print "\n
$joblist[$i]
$joblist[$i]

$prodlist[$i]\n"; print "
"; } ######################プロフィール if($all eq "m_prof"){ print ""; print ""; print "\n"; } else { print "\n"; } print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; $comment2 =~ s/
/\r/g; print "\n"; if($language ne "English"){ print "\n"; print "\n"; } else { print "\n"; print "\n"; } print "
New password
Old password"; if($class_edit){ print "
$field[0]
$field[3]
$field[4]
$field[5] ($field[18])
$field[6]
$field[9]
$field[10]
$field[11]

$field[12]
$field[13]
$field[14]
$field[15]
$field[16]
$field[17]
プロフ画像
プロフ画像の削除
Profile Photo
photo mode
"; } ######################武器魔法スキル if($all eq "m_skill"){ print ""; @skill = split(/,/,$etc[2]); if ($skill_visible) { print "\n"; for($i=0;$i<16;$i++){ print "\n"; } print ""; for($i=0;$i<16;$i++){ print "\n"; } print ""; print "\n"; for($i=16;$i<$#skilllist+1;$i++){ print "\n"; } print ""; for($i=16;$i<$#skilllist+1;$i++){ print "\n"; } print "
$skilllist[$i]
$skilllist[$i]
\n"; } else { print "skill function is not available.
"; } } #######################カスタムフィールド if($all eq "custom"){ print ""; @custom=split(/,/,$prod[11]); for ($i=1;$i<$#custom_field+1;$i++){ if($custom_pulldown[$i]==0){ if($custom_control[$i] eq "0"){ print "$custom_field[$i]
"; } else { print ""; } } else { if($custom_control[$i] eq "0"){ print "$custom_field[$i]
"; } else { print ""; } } } } ######################ミッションアサルト if($all eq "mission"){ print ""; print ""; print ""; print ""; print "\n"; print ""; print "\n"; print ""; print "\n"; print ""; print "\n"; print ""; print "\n"; print ""; print "\n"; print ""; print ""; print "\n"; print ""; print ""; print ""; print "\n"; print ""; print "
Mission
$mlist[15]
$mlist[0]
$mlist[1]
$mlist[2]
$mlist[3]
$mlist[4]

Dynamis
"; print ""; for($k=5;$k<11;$k++){ print ""; } print ""; for($k=5;$k<11;$k++){ print ""; } print ""; print ""; for($k=11;$k<15;$k++){ print ""; } print ""; for($k=11;$k<15;$k++){ print ""; } print ""; print "
$mlist[$k]
$mlist[$k]
\n

Assault
$aslist[0]
"; for($j=2;$j<8;$j++){ print ""; } print ""; for($j=1;$j<6;$j++){ print ""; } #ナイズル print "\n"; print ""; for($j=6;$j<19;$j=$j+3){ print ""; } print ""; for($j=6;$j<19;$j=$j+3){ print ""; } print ""; for($j=7;$j<20;$j=$j+3){ print ""; } print ""; for($j=7;$j<20;$j=$j+3){ print ""; } print ""; for($j=8;$j<21;$j=$j+3){ print ""; } print ""; for($j=8;$j<21;$j=$j+3){ print ""; } print ""; for($j=21;$j<30;$j=$j+2){ print ""; } print ""; for($j=21;$j<30;$j=$j+2){ print ""; } print ""; for($j=22;$j<31;$j=$j+2){ print ""; } print ""; for($j=22;$j<31;$j=$j+2){ print ""; } print ""; for($j=31;$j<40;$j=$j+2){ print ""; } print ""; for($j=31;$j<40;$j=$j+2){ print ""; } print ""; for($j=32;$j<41;$j=$j+2){ print ""; } print ""; for($j=32;$j<41;$j=$j+2){ print ""; } print ""; for($j=41;$j<46;$j++){ print ""; } print ""; for($j=41;$j<46;$j++){ print ""; } print ""; for($j=46;$j<51;$j++){ print ""; } print ""; for($j=46;$j<51;$j++){ print ""; } print ""; for($j=51;$j<56;$j++){ print ""; } print ""; for($j=51;$j<56;$j++){ print ""; } print "
$assaultword[0]
$assaultword[$j]
$aslist[$j]
$aslist[$j]
$aslist[$j]
$aslist[$j]
$aslist[$j]
$aslist[$j]
$aslist[$j]
$aslist[$j]
$aslist[$j]
$aslist[$j]
"; } ####################共通部フッタ print "
"; } ###################### #login_enter & login_modify ###################### sub login_enter{ if($language ne "English"){ print "
ログインメニュー
"; } else { print "
Login Menu
"; } print "MemberList Top
"; print "'$name' LoginMenu
"; print ""; if(!$diaryallow){ print ""; print ""; if($language ne "English"){ print "\n"; } else { print "\n"; } if($oekaki ==1){ if($language ne "English"){ $temp='お絵描き日記'; } else { $temp='Paint Diary'; } print "\n"; } } if($language ne "English"){ print "\n"; print "\n"; } else { print "\n"; print "\n"; } print "\n"; if($language ne "English"){ @templabel=('プロフィール変更','レベル・合成スキル変更','武器魔法スキル変更','ミッション進行度変更','メリットポイント変更'); } else { @templabel=('Modify Profile','Level,Synthesis Skill','Weapon,Magic Skill','Mission Progress','Merit Points'); } #prof print ""; #levelf print ""; #skill print ""; #mission print ""; if($mpoint ==1){ print "\n"; } if($custom_field[0] ne ""){ print "\n"; } $match=0; for($i=0;$i<$#custom_field+1;$i++){ if($custom_control[$i] eq $name){ $match=1; } } if($custom_field[0] ne "" && $match==1){ print "\n"; } print "
新しい日記を書く
Write New Diary
"; print ""; print "
日記を修正・削除する記事番号
Modify or Delete ArticleArticle Number

$templabel[0]
$templabel[1]
$templabel[2]
$templabel[3]
$templabel[4]
"; print ""; print "
$custom_field[0]
"; print ""; print "
担当$custom_field[0]一括入力
"; print ""; print ""; print "
"; } sub login_modify{ # print "modifying=$all
"; #print "
"; #最初に$allをチェックしてマッチファイルから元データを上書きする。 if($all eq "m_prof"){ ($no,$name,$pass,$dummy,$dummy,$dummy,$mainjob,$supportjob,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$etc[1],$etc[2],$prod[0],$prod[1],$prod[2],$prod[3],$prod[4],$prod[5],$prod[6],$prod[7],$prod[8],$prod[9],$prod[10],$prod[11],$prod[12],$prod[13],$prod[14],$prod[15],$lev[0],$lev[1],$lev[2],$lev[3],$lev[4],$lev[5],$lev[6],$lev[7],$lev[8],$lev[9],$lev[10],$lev[11],$lev[12],$lev[13],$lev[14],$lev[15],$lev[16],$lev[17],$lev[18],$lev[19])=split(/\t/,$match); } elsif ($all eq "m_level"){ ($no,$name,$pass,$anon,$race,$relm,$dummy,$dummy,$prof,$handle,$polhn,$mail,$home,$comment2,$point,$class,$time,$comment,$mrank,$etc[0],$dummy,$etc[2],$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$prod[9],$prod[10],$prod[11],$prod[12],$prod[13],$prod[14],$prod[15],$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy,$dummy)=split(/\t/,$match); } elsif ($all eq "m_skill"){ ($no,$name,$pass,$anon,$race,$relm,$mainjob,$supportjob,$prof,$handle,$polhn,$mail,$home,$comment2,$point,$class,$time,$comment,$mrank,$etc[0],$etc[1],$dummy,$prod[0],$prod[1],$prod[2],$prod[3],$prod[4],$prod[5],$prod[6],$prod[7],$prod[8],$prod[9],$prod[10],$prod[11],$prod[12],$prod[13],$prod[14],$prod[15],$lev[0],$lev[1],$lev[2],$lev[3],$lev[4],$lev[5],$lev[6],$lev[7],$lev[8],$lev[9],$lev[10],$lev[11],$lev[12],$lev[13],$lev[14],$lev[15],$lev[16],$lev[17],$lev[18],$lev[19])=split(/\t/,$match); } elsif ($all eq "custom"){ ($no,$name,$pass,$anon,$race,$relm,$mainjob,$supportjob,$prof,$handle,$polhn,$mail,$home,$comment2,$point,$class,$time,$comment,$mrank,$etc[0],$etc[1],$etc[2],$prod[0],$prod[1],$prod[2],$prod[3],$prod[4],$prod[5],$prod[6],$prod[7],$prod[8],$prod[9],$prod[10],$prod[11],$prod[12],$prod[13],$prod[14],$prod[15],$lev[0],$lev[1],$lev[2],$lev[3],$lev[4],$lev[5],$lev[6],$lev[7],$lev[8],$lev[9],$lev[10],$lev[11],$lev[12],$lev[13],$lev[14],$lev[15],$lev[16],$lev[17],$lev[18],$lev[19])=split(/\t/,$match); for($j=1;$j<$#custom_field+1;$j++){ if($custom_control[$j] eq $name){ $custom[$j]=$FORM{"custom$count"."_$j"}; if($FORM{"custom0"} != 0){ $custom[$FORM{"custom0"}] += $FORM{"custom$count"."_$j"}; } } } $prod[11]=join(",", @custom); } elsif ($all eq "mission"){ ($no,$name,$pass,$anon,$race,$relm,$mainjob,$supportjob,$prof,$handle,$polhn,$mail,$home,$comment2,$point,$class,$time,$comment,$mrank,$etc[0],$etc[1],$etc[2],$prod[0],$prod[1],$prod[2],$prod[3],$prod[4],$prod[5],$prod[6],$prod[7],$prod[8],$prod[9],$prod[10],$prod[11],$prod[12],$prod[13],$prod[14],$prod[15],$lev[0],$lev[1],$lev[2],$lev[3],$lev[4],$lev[5],$lev[6],$lev[7],$lev[8],$lev[9],$lev[10],$lev[11],$lev[12],$lev[13],$lev[14],$lev[15],$lev[16],$lev[17],$lev[18],$lev[19])=split(/\t/,$match); # @mission=split(/,/,$prod[15]); $mission[2]=$FORM{"mission2"}; $mission[3]=$FORM{"mission3"}; $mission[4]=$FORM{"mission4"}; for($i=5;$i<15;$i++){ $mission[$i]=$FORM{"mission$i"}; } $mission[1]=$FORM{"mission1"}; $mission[0]=$FORM{"mission0"}; $mission[15]=$FORM{"mission15"}; $mission[16]=$FORM{"assault0"}; for($j=1;$j<$#aslist+1;$j++){ $mission[16]=$mission[16].$FORM{"assault$j"}; } $prod[15]=join(",",@mission); } elsif ($all eq "mpoint"){ ##ここmpoint.plに行くから意味ないっぽ ($no,$name,$pass,$anon,$race,$relm,$mainjob,$supportjob,$prof,$handle,$polhn,$mail,$home,$comment2,$point,$class,$time,$comment,$mrank,$etc[0],$etc[1],$etc[2],$prod[0],$prod[1],$prod[2],$prod[3],$prod[4],$prod[5],$prod[6],$prod[7],$prod[8],$prod[9],$prod[10],$prod[11],$prod[12],$prod[13],$prod[14],$prod[15],$lev[0],$lev[1],$lev[2],$lev[3],$lev[4],$lev[5],$lev[6],$lev[7],$lev[8],$lev[9],$lev[10],$lev[11],$lev[12],$lev[13],$lev[14],$lev[15],$lev[16],$lev[17],$lev[18],$lev[19])=split(/\t/,$match); &list_mpoint_i; @mp=split(/,/,$prod[13]); if($all eq "mpoint1"){ for($i=0;$i<28;$i++){ $mp[$i]=$FORM{"mp$i"} } } if($all eq "mpoint2"){ for($i=28;$i<45;$i++){ $mp[$i]=$FORM{"mp$i"} } } if($all eq "mpoint3"){ for($i=45;$i<141;$i++){ $mp[$i]=$FORM{"mp$i"} } } if($all eq "mpoint4"){ for($i=141;$i<211;$i++){ $mp[$i]=$FORM{"mp$i"} } } $prod[13]=""; $mptotal=0; for($i=0;$i<211;$i++){ $prod[13]=$prod[13].$mp[$i].","; if($mp[$i]>0){ for($j=0;$j<$mp[$i];$j++){ $mptotal= $mptotal + substr($m_needpoint[$i],$j,1); } } } #layout style2 $j=99; #現在カテゴリ $prod[12]="基本グループ1グループ2"; for($i=0;$i<45;$i++){ #基本 if($mp[$i]>0){ if($j !=$m_categorycode[$i]){ $prod[12]=$prod[12]."
$m_categoryname[$m_categorycode[$i]](カテゴリ上限$m_categorymax[$m_categorycode[$i]])
"; $j=$m_categorycode[$i]; } $prod[12]=$prod[12]."$m_name[$i] :".$mp[$i]."/$m_max[$i]
"; } } $prod[12]=$prod[12].""; for($i=45;$i<141;$i++){ #ジョブカテゴリ1 if($mp[$i]>0){ if($j !=$m_categorycode[$i]){ $prod[12]=$prod[12]."
$m_categoryname[$m_categorycode[$i]](カテゴリ上限$m_categorymax[$m_categorycode[$i]])
"; $j=$m_categorycode[$i]; } $prod[12]=$prod[12]."$m_name[$i] :".$mp[$i]."/$m_max[$i]
"; } } $prod[12]=$prod[12].""; for($i=141;$i<211;$i++){ #ジョブカテゴリ2 if($mp[$i]>0){ if($j !=$m_categorycode[$i]){ $prod[12]=$prod[12]."
$m_categoryname[$m_categorycode[$i]](カテゴリ上限$m_categorymax[$m_categorycode[$i]])
"; $j=$m_categorycode[$i]; } $prod[12]=$prod[12]."$m_name[$i] :".$mp[$i]."/$m_max[$i]
"; } } $prod[12]=$prod[12].""; if($mptotal>0){ $prod[12]=$prod[12]."総消費メリットポイント$mptotal"; } } else { ($no,$name,$pass,$anon,$race,$relm,$mainjob,$supportjob,$prof,$handle,$polhn,$mail,$home,$comment2,$point,$class,$time,$comment,$mrank,$etc[0],$etc[1],$etc[2],$prod[0],$prod[1],$prod[2],$prod[3],$prod[4],$prod[5],$prod[6],$prod[7],$prod[8],$prod[9],$prod[10],$prod[11],$prod[12],$prod[13],$prod[14],$prod[15],$lev[0],$lev[1],$lev[2],$lev[3],$lev[4],$lev[5],$lev[6],$lev[7],$lev[8],$lev[9],$lev[10],$lev[11],$lev[12],$lev[13],$lev[14],$lev[15],$lev[16],$lev[17],$lev[18],$lev[19])=split(/\t/,$match); } #error_check if( !($name2 =~ /^[A-Za-z0-9_]+$/) && $name2 != ""){ if($language ne "English"){ &header;&error_message('そのパスワードは登録に利用できません。','パスワードは半角英数字で登録してください。'); } else { &header;&error_message('That password is unsuitable.','Password must use a-z and 0-9 letters.'); } } if($language ne "English"){ if($mainjob == $supportjob){&header; &error_message('main/job error','メインとサポートは同一のジョブにはできません');} } else { if($mainjob == $supportjob){&header; &error_message('main/job error',"Support job can not set as main's one.");} } &prof_image; if($imgexist){ ($type,$h,$w) = &image_getsize("$imgdir$imgfile"); $prod[14]="$h,$w,$imgfile"; } if($imgdel){ ($h,$w,$imgfile) = split(/\,/ , $prod[14]); unlink("$imgdir$imgfile"); $prod[14]=""; } &dirlock; if(!open(IN,"$datafile")){&error_message('datafile error612i','data file access failed.');} @all=; close IN; @out=(); foreach $i(@all){ ($r_no,$r_name,$r_pass,$r_dummy)=split(/\t/,$i); if($r_name eq $name && $pass eq $r_pass){ if($name2 ne ""){$pass=$name2;} $pastdat=$i; $newdat="$r_no\t$name\t$pass\t$anon\t$race\t$relm\t$mainjob\t$supportjob\t$prof\t$handle\t$polhn\t$mail\t$home\t$comment2\t$point\t$class\t$timenow\t$comment\t$mrank\t$etc[0]\t$etc[1]\t$etc[2]\t$prod[0]\t$prod[1]\t$prod[2]\t$prod[3]\t$prod[4]\t$prod[5]\t$prod[6]\t$prod[7]\t$prod[8]\t$prod[9]\t$prod[10]\t$prod[11]\t$prod[12]\t$prod[13]\t$prod[14]\t$prod[15]\t$lev[0]\t$lev[1]\t$lev[2]\t$lev[3]\t$lev[4]\t$lev[5]\t$lev[6]\t$lev[7]\t$lev[8]\t$lev[9]\t$lev[10]\t$lev[11]\t$lev[12]\t$lev[13]\t$lev[14]\t$lev[15]\t$lev[16]\t$lev[17]\t$lev[18]\t$lev[19]\t\n"; push(@out,$newdat); } else { push(@out,$i); } } if(!open(OUT,">$datafile")){&header; &error_message('datafile error627i','data file access failed.');} print OUT @out; close OUT; rmdir($lockdir); #RSS用履歴ファイル作成 &compare_history; $historybase="PROFED\t$name\t$name profile modify\t$rsstime\t$no\t$message\t$rh\t$addr\t\n"; &add_history; &set_cookie; &reload_header; if($language ne "English"){ print "
修正終了
"; print "MemberList Top
"; print "修正を行いました。自動的にトップページへ戻ります。
"; } else { print "
Information modified
"; print "Automatically move top page.
"; } } ###################### #login_enter & login_modify ###################### sub prof_skill{ if(($anon ne "on") || ($anon_mode != 1 )){ ################# #-- 以下、スキル表示機能で追加した部分 if ($skill_visible) { @skill = split(/,/,$etc[2]); for ($j=0;$j<$#skilllist+1;$j++){ $skillmax[$j] = -1; for ($k=0;$k<$job_max;$k++){ if (int($lev[$k]) > 0) { $askill = expr_skillcap($k, $j, $lev[$k]); if ($askill > $skillmax[$j]) { $skillmax[$j] = $askill; $skillmaxjob[$j] = $k; } } } } if ($FORM{'skilldetail'} eq "") { print ""; for ($j=0;$j<$#skilllist+1;$j++){ print ""; } print ""; print ""; for ($j=0;$j<$#skilllist+1;$j++){ if ($skillmax[$j] > int($skill[$j])) { print ""; } else { print ""; } } print ""; print ""; for ($j=0;$j<$#skilllist+1;$j++){ print ""; } print ""; print ""; for ($j=0;$j<$#skilllist+1;$j++){ print ""; } if($language ne "English"){ print "
$skilllist[$j]
Now$skill[$j]$skill[$j]
Cap"; print $skillmax[$j]; print "
Job"; print $joblist[$skillmaxjob[$j]]; print "
ジョブごとの詳細キャップを表\示する。
"; } else { print "Show skill limit detail
";} } elsif ($FORM{'skilldetail'} eq "true") { print ""; for ($j=0;$j<$#skilllist+1;$j++){ print ""; } print ""; print ""; for ($j=0;$j<$#skilllist+1;$j++){ if ($skillmax[$j] > int($skill[$j])) { print ""; } else { print ""; } } print ""; for ($k=0;$k<$job_max;$k++){ if (int($lev[$k]) > 0) { print ""; for ($j=0;$j<$#skilllist+1;$j++){ if ($skillmaxjob[$j] == $k) { print ""; } print ""; } } if($language ne "English"){ print "
$skilllist[$j]
Now$skill[$j]$skill[$j]
$joblist[$k]"; } else { print ""; } $skillcap = expr_skillcap($k, $j, $lev[$k]); if ($skillcap > 0) { if ($skillcap > int($skill[$j])) { print $skillcap; } else { print "$skillcap"; } } print "
詳細キャップ表\示をやめる。  スキルランクを表\示する。
"; } else { print "Exit detail info  Show skill rank
"; } } elsif ($FORM{'skilldetail'} eq "rank") { print ""; for ($j=0;$j<$#skilllist+1;$j++){ print ""; } print ""; print ""; for ($j=0;$j<$#skilllist+1;$j++){ if ($skillmax[$j] > int($skill[$j])) { print ""; } else { print ""; } } print ""; for ($k=0;$k<$job_max;$k++){ if (int($lev[$k]) > 0) { print ""; for ($j=0;$j<$#skilllist+1;$j++){ $skillrank = substr($skillrank[$k],$j * 2, 2); print ""; } print ""; } } if($language ne "English"){ print "
$skilllist[$j]
Now$skill[$j]$skill[$j]
$joblist[$k]"; if ($skillrank eq "_ ") { print "\ "; } else { print "$skillrank"; } print "
ランク表\示をやめる。
"; } else { print "Exit rank info
"; } } } #-- スキル表示機能で追加した部分ここまで ################# } } sub prof_meritpoint{ ##メリポ表示(仮) mpoint.plで$prod[12]に表示用データを作成している if($language ne "English"){ print "
"; } else { print "
メリットポイント
"; } print "$prod[12]\n"; print "
Merit point
"; ##メリポ表示ここまで } sub prof_customfield{ ##カスタムフィールド @custom=split(/,/,$prod[11]); print ""; for($j=1;$j<$#custom_field+1;$j++){ print ""; } print ""; for($j=1;$j<$#custom_field+1;$j++){ if($custom_pulldown[$j]==0){ print ""; } else { print ""; } } print "
$custom_field[$j]
$custom[$j]".${"custom_list$j"}[$custom[$j]]."
\n"; } sub prof_levelbox{ #ジョブレベル合成スキル表示 if(($anon ne "on") || ($anon_mode != 1 )){ if($class_edit==0){ $class =~ s/<//g; } if($job_max>$prod_max){ $maxcell=$job_max; } else { $maxcell=$prod_max; } print ""; for ($j=0;$j<$maxcell;$j++){ $jn=$j+38; if($j<$job_max){ print ""; } else { print ""; } } print ""; for ($j=0;$j<$maxcell;$j++){ $jn=$j+22; if($j<$prod_max){ print ""; } elsif ($j == $prod_max) { print ""; } } print ""; print ""; if($name eq $c_name){$bgn=" bgcolor=$mydata";} else {$bgn=" bgcolor=$otherdata";} if($class eq ""){$class=" ";} if($point eq ""){$point=0;} print ""; if(($anon ne "on") || ($anon_mode != 1 )){ if($lev[$mainjob]<10){ $main_level="0$lev[$mainjob]"; } else { $main_level=$lev[$mainjob]; } if($supportjob <99){ $mod_level=int($lev[$mainjob]/2); if($mod_level==0){$mod_level=1;} if($mod_level>$lev[$supportjob]){$mod_level=$lev[$supportjob];} if($mod_level<10){ $mod_level="0$mod_level"; } print ""; } else { print ""; } $totalexp = 0; for ($j=0;$j<$maxcell;$j++){ $bg=""; if($j<$job_max){ $totalexp += expr_exp($lev[$j]); if($level ==1){ $bg=" bgcolor=$color[int($lev[$j]/10)]"; } else { if($j == $mainjob){$bg=" bgcolor=$maincolor";} if($j == $supportjob){$bg=" bgcolor=$supportcolor";} } print "$lev[$j]"; } else { print ""; } } } else { for ($j=0;$j<$maxcell+1;$j++){ print""; } } $date=substr($time,0,8); print ""; if(($anon ne "on") || ($anon_mode != 1 )){ if($prod[12] =~m /イント<\/TD>"; } elsif ($j == $prod_max) { print ""; } } } else { for ($j=0;$j<$maxcell+1;$j++){ print""; } } print ""; print ""; print "
$index[0]$index[1]$index[2]$index[3]$index[4]$index[5]$index[6]$index[7]$joblist[$j]
$prodlist[$j]Main NextTotal Exp.
$index[9]
$no$class$name"; if($iconuse eq "yes"){ print ""; } else { print "$racelist[$race]"; } print "$relmlist[$relm]$point$mrank$joblist[$mainjob]$main_level/$joblist[$supportjob]$mod_level$joblist[$mainjob]$main_level -
([0-9]+)<\/TD>/ ){ $mpointexp = $1*10000; } if($prod[12] =~m /use<\/TD>([0-9]+)<\/TD>/ ){ $mpointexp = $1*10000; } if($mpointexp>0){ if($mexpmode == 1){ $totalexp=$totalexp+$mpointexp; } else { $totalexp="$totalexp+".$mpointexp; } } for ($j=0;$j<$maxcell;$j++){ if($j<$prod_max){ $bg=" bgcolor=$color[$prod_r[$j]]"; print "$prod[$j]".expr_needexp($lev[$mainjob])." ".$totalexp." -
$comment
"; } # anon mode on #ジョブレベル合成スキル表示部終了 } sub prof_box{ ##プロフィールBOX if($prof ne "off"){ if($language ne "English"){ print ""; if($prod[14]){ ($h,$w,$prod[14])=split(/\,/,$prod[14]); if($h>$w){ if($h>200){ $w=int($w/$h*200);$h=200; } } else { if($w>200){ $h=int($h/$w*200);$w=200; } } print ""; } else { print ""; } print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "
$name さんのプロフィール
ハンドル$handle
POLハンドル$polhn
e-mail$mail
ホームページ$home
コメント$comment2
"; } else { print ""; if($prod[14]){ ($h,$w,$prod[14])=split(/\,/,$prod[14]); if($h>$w){ if($h>200){ $w=int($w/$h*200);$h=200; } } else { if($w>200){ $h=int($h/$w*200);$w=200; } } print ""; } else { print ""; } print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "
$name 's profile
Handlename$handle
POL Handlename$polhn
e-mail$mail
Homepage$home
Comment$comment2
"; } } else { if($language ne "English"){ print "
$name さんのプロフィールは非公開となっています。
"; } else { print "
$name 's profile is closed.
"; } } ##プロフィールBOXここまで } #個人プロフ・日記表示メイン # prof_box プロフィールBOX # prof_detail 詳細プロフィール # prof_levelbox レベル関連表示 # show_dairy 日記表示 sub prof { print ""; print "
"; print ""; &make_salt; print ""; print <<"EOM";
$guild_name Member ListProfile : $name
$menux[3]$menux[1] / "; print "$menux[2] / "; print "$menux[4] / "; if($bbspage){print " $menux[0]";} print "
Login : name pass EOM if(!$diaryallow){print "";} if($key_avail){ print ""; } if($mes_avail){ print "
Message : to '$name'"; } print <<"EOM";
EOM if($reg_mode==0){print "";} print ""; print "

"; if(!open(IN,"$datafile")){&error_message('datafile error2098','data file access failed.');} @all=; close IN; $match=""; foreach $i(@all){ ($r_no,$r_name,$r_pass,$r_dummy)=split(/\t/,$i); if($r_name eq $name){ $match=$i; } } if($match eq ""){&header; &error_message('id/pass error','access failed.');} ($no,$name,$pass,$anon,$race,$relm,$mainjob,$supportjob,$prof,$handle,$polhn,$mail,$home,$comment2,$point,$class,$time,$comment,$mrank,$etc[0],$etc[1],$etc[2],$prod[0],$prod[1],$prod[2],$prod[3],$prod[4],$prod[5],$prod[6],$prod[7],$prod[8],$prod[9],$prod[10],$prod[11],$prod[12],$prod[13],$prod[14],$prod[15],$lev[0],$lev[1],$lev[2],$lev[3],$lev[4],$lev[5],$lev[6],$lev[7],$lev[8],$lev[9],$lev[10],$lev[11],$lev[12],$lev[13],$lev[14],$lev[15],$lev[16],$lev[17],$lev[18],$lev[19])=split(/\t/,$match); @prod_r = split(/,/,$etc[1]); if($function eq "profdetail"){ if($language ne "English"){ @templabel=('日記を読む','レベル・合成スキル','プロフィール','ミッション進行度','武器・魔法スキル','メリットポイント','↑'); } else { @templabel=('Read Diary','Level,Synthesis','Profile','Mission Progress','Weapon,Magic Skill','Meritpoint','[top]'); } if($name eq $c_name){$bgn=" bgcolor=$mydata";} else {$bgn=" bgcolor=$otherdata";} print "
$templabel[0]
"; print "$templabel[1] $templabel[2] $templabel[3],$custom_field[0] $templabel[4] $templabel[5]"; if($name eq $c_name){$bgn=" bgcolor=$mydata";} print "
$templabel[1]"; &prof_levelbox; print "
$templabel[2]"; &prof_box; print "
$templabel[3],$custom_field[0]"; &prof_mission2; print "
$templabel[4]"; &prof_skill; print "$templabel[5]"; &prof_meritpoint; } else { #prof if($language ne "English"){ print " 詳細なプロフィールを確認する
"; } else { print " Show Detail Profile
"; } &show_diary; } } #end of sub prof sub write_images{ $fnt=""; $imgno="1"; foreach $upfilename (@upfiles){ $shortupfilename = $1 if $upfilename =~ /[\\|\/]?([0-9a-zA-Z_\.]+)$/; if($language ne "English"){ if( length($upfile{$upfilename}) > $maxsize){&header;&error_message("ファイルサイズが大きすぎます。","");} } else { if( length($upfile{$upfilename}) > $maxsize){&header;&error_message("Too mach file size.","");} } ($filename,$fileexst) = ($1,$2) if $shortupfilename =~ /(.*)\.(\w+)$/; $fileexst=lc($fileexst); $a1=0; foreach(@permitup){ if ($_ eq $fileexst){$a1=1;last;} } if($language ne "English"){ if(!($a1)) {&header;&error_message("拡張子 $fileexst はアップが許可されていません($in{'upct'})。","");} } else { if(!($a1)) {&header;&error_message("extension $fileexst is not allowed to upload($in{'upct'}).","");} } open(IMGOUT,">$imgdir$name$maxno\_$imgno.$fileexst"); binmode(IMGOUT); print IMGOUT $upfile{$upfilename}; close(IMGOUT); push(@fnt,"$name$maxno\_$imgno.$fileexst"); $imgexist=1; $imgno++; } $fnt=join(",", @fnt); } sub write_diary{ $diaryfile="$diarydir$name.$diaryletter"; $imgexist=0; if(!open(IN,"$datafile")){&header; &error_message('datafile error2249','data file access failed.');} @all=; close IN; $match=""; foreach $i(@all){ ($r_no,$r_name,$r_pass,$r_dummy)=split(/\t/,$i); if($r_name eq $name && $pass eq $r_pass){ $match=$i; } } if($match eq ""){&header; &error_message('id/pass error','access failed.');} if ($mode eq "write"){ if($language ne "English"){ if($body eq ""){&header;&error_message('本文がありません','');} } else { if($body eq ""){&header;&error_message('Message is blank.','');} } if (!open(DB,"$diaryfile")) { @lines=(); } @lines = ; close(DB); ($maxno,$dummy1,$dummy2,$dummy3)=split(/\t/,$lines[0]); $maxno++; #あげ対策 $maxno=time(); &write_images; #キーワード対応、新規日記 if($key_avail){ &jcode'convert(*body,'euc'); $count=1; $mcount=0; foreach $i(@keyword){ ($km,$keyno)=split(/\t/,$i); # print $count. "$km
"; &jcode'convert(*km,'euc'); $body =~ s/$km/$km<\/a>/g; if($& eq $km){$mes='';&update_keyword;} $count++; } &jcode'convert(*body,'sjis'); } #キーワード対応ここまで追加 @lines=reverse(@lines); push(@lines,"$maxno\t$today2\t$title\t$body\t$fnt\t\t\n"); @lines=reverse(@lines); @out=(); $count=0; foreach $i(@lines){ if($count<$diarymax){ push(@out,$i); $count++; } } if (!open(OUT,">$diaryfile")) {&header; &error_message('filesystem error','access failed.');} print OUT @out; close(OUT); chmod 0666,$diaryfile; if(!open(IN,"$datafile")){&error_message('datafile error2315','data file access failed.');} @all=; close IN; @out=(); foreach $i(@all){ ($no,$r_name,$pass,$anon,$race,$relm,$mainjob,$supportjob,$prof,$handle,$polhn,$mail,$home,$comment2,$point,$class,$time,$comment,$mrank,$etc[0],$etc[1],$etc[2],$prod[0],$prod[1],$prod[2],$prod[3],$prod[4],$prod[5],$prod[6],$prod[7],$prod[8],$prod[9],$prod[10],$prod[11],$prod[12],$prod[13],$prod[14],$prod[15],$lev[0],$lev[1],$lev[2],$lev[3],$lev[4],$lev[5],$lev[6],$lev[7],$lev[8],$lev[9],$lev[10],$lev[11],$lev[12],$lev[13],$lev[14],$lev[15],$lev[16],$lev[17],$lev[18],$lev[19])=split(/\t/,$i); $lev[15] =~ s/\n//g; $lev[16] =~ s/\n//g; if($r_name eq $name){ push(@out,"$no\t$r_name\t$pass\t$anon\t$race\t$relm\t$mainjob\t$supportjob\t$prof\t$handle\t$polhn\t$mail\t$home\t$comment2\t$point\t$class\t$timenow\t$comment\t$mrank\t$etc[0]\t$etc[1]\t$etc[2]\t$prod[0]\t$prod[1]\t$prod[2]\t$prod[3]\t$prod[4]\t$prod[5]\t$prod[6]\t$prod[7]\t$prod[8]\t$prod[9]\t$prod[10]\t$prod[11]\t$prod[12]\t$prod[13]\t$prod[14]\t$prod[15]\t$lev[0]\t$lev[1]\t$lev[2]\t$lev[3]\t$lev[4]\t$lev[5]\t$lev[6]\t$lev[7]\t$lev[8]\t$lev[9]\t$lev[10]\t$lev[11]\t$lev[12]\t$lev[13]\t$lev[14]\t$lev[15]\t$lev[16]\t$lev[17]\t$lev[18]\t$lev[19]\t\n"); } else { push(@out,$i); } } if(!open(OUT,">$datafile")){&header; &error_message('datafile error2329','data file access failed.');} print OUT @out; close OUT; #RSS用履歴ファイル作成 $historybase="DWRITE\t$name\t$title\t$rsstime\t$maxno\t$body\t$rh\t$addr\t\n"; &add_history; &reload_header; if($language ne "English"){ print "
書き込み終了
"; print "
MemberList Top
"; print "日記を書き込みました。自動的にトップページに戻ります
"; } else { print "
Writing finished.
"; print "Writing diray is done. Go back to top page.
"; } } elsif ($mode eq "oekaki"){ &header; if($language ne "English"){ print "
日記を書き込みます
"; } else { print "
Diary Writing Mode
"; } print "Go Top
"; print <<"EOM";
BBS Painter by ば科学的愛情
EOM } else { &header; if($language ne "English"){ print "
日記を書き込みます
"; } else { print "
Diary Writing Mode
"; } print "Go Top
"; print "
\ntitle

body

"; if($language ne "English"){ if($imgallow == 1){ for ($i=1; $i <= $imgmax; $i++){ print "画像$i
"; } } } else { if($imgallow == 1){ for ($i=1; $i <= $imgmax; $i++){ print "Image$i
"; } } } print"
"; } } sub show_diary { $diaryfile="$diarydir$name.$diaryletter"; if($diarybg ne ""){$dbg=" bgcolor=$diarybg";} if (!open(DB,"$diaryfile")) { if($language ne "English"){ print "
$name さんの日記はありません。
"; } else { print "
$name 's diray doesn't exist.
"; } } else { @lines = ; close(DB); if($language ne "English"){ print "
Diary Index
$name さんの日記。($showmax件表\示)

"; } else { print "
Diary Index
$name 's diary($showmax articles)

"; } if($page ne "all"){ print ""; $min=($page-1)*$showmax-1; $max=$page*$showmax; $count=0; foreach $i (@lines){ ($rno,$today2,$title,$body,$imgexist,$res)=split(/\t/,$i); if( ($mode eq "" && $count>$min && $count<$max )|| ($mode ne "" && $mode == $rno) ){ if(($name eq $c_name) && ($pass eq $c_pass)){ if($language ne "English"){ print ""; } else { print ""; } } else { print ""; } $body =~ s/(https?|ftp|gopher|telnet|whois|news)\:([\w|\:\!\#\$\%\=\&\-\^\`\\\|\@\~\[\{\]\}\;\+\*\,\.\?\/]+)/$1\:$2<\/a>/ig; print "
"; if($imgexist ne ""){ print "
$title (open) [修正・削除]$today2($rno)
$title (open) [edit/delete]$today2($rno)
$title(open)$today2($rno)
"; @imgfiles = split(/,/,$imgexist); foreach $imgfile(@imgfiles){ ($type,$h,$w) = &image_getsize("$imgdir$imgfile"); if($h>$w){ if($h>200){ $w=int($w/$h*200);$h=200; } } else { if($w>200){ $h=int($h/$w*200);$w=200; } } print "クリックで拡大
"; } print "
$body

"; } else { print "$body
"; } if($res ne ""){ print "$res
"; } if($diaryres){ if($language ne "English"){ print "名前"; } else { print "Name"; } } print ""; } $count++; } if($mode eq ""){ if($page>1){ $flag++; $bpage=$page-1; if($language ne "English"){ $before="
前のページ"; } else { $before="former page"; } } if($count>$max){ $flag++; $page++; if($language ne "English"){ $after="次のページ"; } else { $after="next page"; } } if($flag){ print " "; print "$before "; print "$after"; } } print ""; } #page=all else { @all=""; foreach $i (@lines){ ($rno,$today2,$title,$body,$imgexist,$res)=split(/\t/,$i); if($today2 =~ /^[0-9][0-9]\/[0-9][0-9]\s(.*)/){$today2=" $today2";} push(@all,"$today2\t$rno\t$title\t$body\t$imgexist\t$res\n"); } @lines=reverse(sort(@all)); foreach $i (@lines){ ($rno,$today2,$title,$body,$imgexist,$res)=split(/\t/,$i); if($rno ne ""){ print "$title($rno)
\n"; } } } } } sub res_diary{ if($language ne "English"){ if($body eq ""){&header;&error_message('本文がありません','');} if($name eq ""){&header;&error_message('名前がありません','');} if ($body !~ /[\x81-\x9A]/ && $denyeng){&header;&error_message('アルファベットのみの書き込みは禁止されています。','');} } else { if($body eq ""){&header;&error_message('no text','');} if($name eq ""){&header;&error_message('no name','');} } &word_ban; if( $body =~ /
/) { $body="
$body
"; } $diaryfile="$diarydir$name2.$diaryletter"; &dirlock; if (!open(DB,"$diaryfile")) { &header; if($language ne "English"){ print "
$name さんの日記はありません。
"; } else { print "
$name's diary is not exist.
"; } } else { @lines = ; close(DB); foreach $i(@lines){ ($r_no,$r_today,$r_title,$r_body,$r_img,$r_res)=split(/\t/,$i); if($no !=$r_no){ push(@out,$i); } else { $r_res =~ s/\n//g; $r_res.="$name > $body ($today2)
"; $r_body =~ s/\n//g; #旧バージョン対策 if($sage == 0){ push(@out,"$r_no\t$r_today\t$r_title\t$r_body\t$r_img\t$r_res\t\n"); } else { $ageline="$r_no\t$r_today\t$r_title\t$r_body\t$r_img\t$r_res\t\n"; } } } if($sage !=0){ unshift(@out,$ageline); } if (!open(OUT,">$diaryfile")) {&header; &error_message('filesystem error','access failed.');} print OUT @out; close(OUT); #RSS用履歴ファイル作成 $rsstime="20$year-$mon-$mday"."T$hour:$min:00+09:00"; $historybase="RESDIA\t$name $name2\t$timenow\t$rsstime\t$no\t$body\t$rh\t$addr\t\n"; &add_history; if(!open(IN,"$datafile")){&error_message('datafile error2480','data file access failed.');} @all=; close IN; @out=(); foreach $i(@all){ ($no,$r_name,$pass,$anon,$race,$relm,$mainjob,$supportjob,$prof,$handle,$polhn,$mail,$home,$comment2,$point,$class,$time,$comment,$mrank,$etc[0],$etc[1],$etc[2],$prod[0],$prod[1],$prod[2],$prod[3],$prod[4],$prod[5],$prod[6],$prod[7],$prod[8],$prod[9],$prod[10],$prod[11],$prod[12],$prod[13],$prod[14],$prod[15],$lev[0],$lev[1],$lev[2],$lev[3],$lev[4],$lev[5],$lev[6],$lev[7],$lev[8],$lev[9],$lev[10],$lev[11],$lev[12],$lev[13],$lev[14],$lev[15],$lev[16],$lev[17],$lev[18],$lev[19])=split(/\t/,$i); $lev[15] =~ s/\n//g; $lev[16] =~ s/\n//g; if($r_name eq $name2){ push(@out,"$no\t$r_name\t$pass\t$anon\t$race\t$relm\t$mainjob\t$supportjob\t$prof\t$handle\t$polhn\t$mail\t$home\t$comment2\t$point\t$class\t$timenow\t$comment\t$mrank\t$etc[0]\t$etc[1]\t$etc[2]\t$prod[0]\t$prod[1]\t$prod[2]\t$prod[3]\t$prod[4]\t$prod[5]\t$prod[6]\t$prod[7]\t$prod[8]\t$prod[9]\t$prod[10]\t$prod[11]\t$prod[12]\t$prod[13]\t$prod[14]\t$prod[15]\t$lev[0]\t$lev[1]\t$lev[2]\t$lev[3]\t$lev[4]\t$lev[5]\t$lev[6]\t$lev[7]\t$lev[8]\t$lev[9]\t$lev[10]\t$lev[11]\t$lev[12]\t$lev[13]\t$lev[14]\t$lev[15]\t$lev[16]\t$lev[17]\t$lev[18]\t$lev[19]\t\n"); } else { push(@out,$i); } } if(!open(OUT,">$datafile")){&header; &error_message('datafile error2494','data file access failed.');} print OUT @out; close OUT; rmdir($lockdir); &reload_header2; if($language ne "English"){ print "
書き込み終了
"; print "MemberList Top
"; print "自動的に戻ります
"; } else { print "
Writing finished.
"; print "Automatically back former page.
"; } } } sub edit_diary{ $diaryfile="$diarydir$name.$diaryletter"; if(!open(IN,"$datafile")){&header; &error_message('datafile error2511','data file access failed.');} @all=; close IN; $match=""; foreach $i(@all){ ($r_no,$r_name,$r_pass,$r_dummy)=split(/\t/,$i); if($r_name eq $name && $pass eq $r_pass){ $match=$i; } } if($match eq ""){&header; &error_message('id/pass error','access failed.');} if ($mode eq "del"){ &dirlock; if (!open(DB,"$diaryfile")) { &header; print "
$name さんの日記はありません。
"; rmdir($lockdir); } else { @lines = ; close(DB); foreach $i(@lines){ ($r_no,$r_today,$r_title,$r_body,$r_imgexist,$r_res)=split(/\t/,$i); if($no !=$r_no){ push(@out,$i); } else { unlink("$imgdir$r_imgexist"); } } if (!open(OUT,">$diaryfile")) {&header; &error_message('filesystem error','access failed.');} print OUT @out; close(OUT); if(!open(IN,"$datafile")){&error_message('datafile error2549','data file access failed.');} @all=; close IN; @out=(); foreach $i(@all){ ($no,$r_name,$pass,$anon,$race,$relm,$mainjob,$supportjob,$prof,$handle,$polhn,$mail,$home,$comment2,$point,$class,$time,$comment,$mrank,$etc[0],$etc[1],$etc[2],$prod[0],$prod[1],$prod[2],$prod[3],$prod[4],$prod[5],$prod[6],$prod[7],$prod[8],$prod[9],$prod[10],$prod[11],$prod[12],$prod[13],$prod[14],$prod[15],$lev[0],$lev[1],$lev[2],$lev[3],$lev[4],$lev[5],$lev[6],$lev[7],$lev[8],$lev[9],$lev[10],$lev[11],$lev[12],$lev[13],$lev[14],$lev[15],$lev[16],$lev[17],$lev[18],$lev[19])=split(/\t/,$i); $lev[15] =~ s/\n//g; $lev[16] =~ s/\n//g; if($r_name eq $name){ push(@out,"$no\t$r_name\t$pass\t$anon\t$race\t$relm\t$mainjob\t$supportjob\t$prof\t$handle\t$polhn\t$mail\t$home\t$comment2\t$point\t$class\t$timenow\t$comment\t$mrank\t$etc[0]\t$etc[1]\t$etc[2]\t$prod[0]\t$prod[1]\t$prod[2]\t$prod[3]\t$prod[4]\t$prod[5]\t$prod[6]\t$prod[7]\t$prod[8]\t$prod[9]\t$prod[10]\t$prod[11]\t$prod[12]\t$prod[13]\t$prod[14]\t$prod[15]\t$lev[0]\t$lev[1]\t$lev[2]\t$lev[3]\t$lev[4]\t$lev[5]\t$lev[6]\t$lev[7]\t$lev[8]\t$lev[9]\t$lev[10]\t$lev[11]\t$lev[12]\t$lev[13]\t$lev[14]\t$lev[15]\t$lev[16]\t$lev[17]\t$lev[18]\t$lev[19]\t\n"); } else { push(@out,$i); } } if(!open(OUT,">$datafile")){&header; &error_message('datafile error2563','data file access failed.');} print OUT @out; close OUT; rmdir($lockdir); #RSS用履歴ファイル作成 $historybase="DERASE\t$name\t$title\t$rsstime\t$no\t$body\t$rh\t$addr\t\n"; &add_history; &reload_header; print "
削除終了
"; print "MemberList Top
"; print "記事No.$noを削除しました。自動的にトップページに戻ります
"; if(-z $diaryfile){ print "日記が全て削除されました。
"; unlink($diaryfile); } } } elsif ($mode eq "modify"){ if (!open(DB,"$diaryfile")) { &header; print "
$name さんの日記はありません。
"; rmdir($lockdir); } else { @lines = ; close(DB); $imgexist=0; if ($in{'upfile'} ne ""){ $in{'upfilename'} = $1 if $in{'upfilename'} =~ /[\\|\/]?([0-9a-zA-Z_\.]+)$/; if( length($in{'upfile'}) > $maxsize){&header;&error_message("ファイルサイズが大きすぎます。","");} ($filename,$fileexst) = ($1,$2) if $in{'upfilename'} =~ /(.*)\.(\w+)$/; $fileexst=lc($fileexst); $a1=0; foreach(@permitup){ if ($_ eq $fileexst){$a1=1;last;} } if(!($a1)) {&header;&error_message("拡張子 $fileexst はアップが許可されていません($in{'upct'})。","");} $newname = "$name$no.$fileexst"; if (-e "$imgdir$newname") { $fileno = 2; while (-e "$imgdir$name${no}_$fileno.$fileexst") { $fileno++; } $newname = "$name${no}_$fileno.$fileexst"; } open(IMGOUT,">$imgdir$newname"); binmode(IMGOUT); print IMGOUT $in{'upfile'}; close(IMGOUT); $imgexist=1; } #キーワード対応(修正) if($key_avail){ &jcode'convert(*body,'euc'); $count=1; $mcount=0; foreach $i(@keyword){ ($km,$keyno)=split(/\t/,$i); # print $count. "$km
"; &jcode'convert(*km,'euc'); $body =~ s/$km/$km<\/a>/g; if($& eq $km){$maxno=$no;$mes='(update)';&update_keyword;} $count++; } &jcode'convert(*body,'sjis'); } #キーワード対応(ここまで) #レス修正時に$body2の後部に
がない場合は追記する if($body2 ne "" && !($body2 =~ /
$/)) { $body2 ="$body2
"; } foreach $i(@lines){ ($r_no,$r_today,$r_title,$r_body,$r_imgexist,$r_res)=split(/\t/,$i); if($no==$r_no){ $body =~ s/\n//g; $body2 =~ s/\n//g; $deleteimg = $FORM{'deleteimg'}; @imgexists_n = (); @imgexists = split(/,/,$r_imgexist); foreach $imgfile (@imgexists) { if ($deleteimg eq $imgfile && $comment eq "delete") { unlink("$imgdir$deleteimg"); } else { push(@imgexists_n, $imgfile); } } if ($imgexist) { push(@imgexists_n, $newname); } $r_imgexist = join(",", @imgexists_n); push(@out,"$no\t$today2\t$title\t$body\t$r_imgexist\t$body2\t\n"); } else { push(@out,$i); } } if (!open(OUT,">$diaryfile")) {&header; &error_message('filesystem error','access failed.');} print OUT @out; close(OUT); rmdir($lockdir); #RSS用履歴ファイル作成 $historybase="DMODIF\t$name\t$title\t$rsstime\t$no\t$body\t$rh\t$addr\t\n"; &add_history; &reload_header; print "
修正終了
"; print "
MemberList Top
"; print "日記を修正しました。自動的にトップページに戻ります
"; } } else { &header; if (!open(DB,"$diaryfile")) { print "
$name さんの日記はありません。
"; } else { @lines = ; close(DB); foreach $i (@lines){ ($r_no,$r_today,$r_title,$r_body,$r_imgexist,$r_res)=split(/\t/,$i); if($no==$r_no){ $hit=$i;} } if($hit eq ""){&header; &error_message('no such number','access failed.');} ($r_no,$r_today,$r_title,$r_body,$r_imgexist,$r_res)=split(/\t/,$hit); print "
日記の修正・削除を行います
"; print "Go Top
"; $r_body =~ s/
/\n/g; $r_body =~ s/<//g; $r_body =~ s/]*>//g; $r_body =~ s/<\/a>//g; print "
\n 記事No. $no
title

body

res
"; $r_res =~ s/
/\n/g; $r_res =~ s/<//g; $r_res =~ s/]*>//g; $r_res =~ s/<\/a>//g; print "
"; foreach $imgexist (split(/,/,$r_imgexist)) { print "クリックで拡大選択
"; } if($r_imgexist ne ""){print "選択した画像の消去
";} print "画像を追加

"; print " "; } } } sub dirlock { if($lockdir eq ""){return;} if((-M $lockdir)>0.001){ #1分半ほどlockdirが存在している場合は強制的に削除 rmdir($lockdir); } for ($i = 0; $i <= 20; $i++) { if (mkdir($lockdir, 0755)) { last; } else { sleep(1); } } $SIG{'TERM'} = $SIG{'PIPE'} = $SIG{'HUP'} = "sigexit"; if($i == 20){&error_message('busy','now busy, please access later.');} } sub sigexit { rmdir($lockdir); exit(1); } sub keitai { &make_salt; require('keitai.pl'); &header_i; print ""; print "$guild_name List
"; if($function eq "$button[0]"){ &login_i; } elsif($function eq "mission"){ &login_i; } elsif($function eq "prof"){ &prof_i; } elsif($function eq "$button[1]"){ if(!$diaryallow){ &write_diary_i; } } elsif($function eq "new"){ &new_regist_i; } elsif($function eq "diary"){ &diary_i; } elsif($function eq "resdiary"){ &res_diary_i; &diary_i; } elsif($function eq 'send' && $mes_avail == 1){ &send_message_i; } elsif($function eq 'check' && $mes_avail == 1){ &check_message_i; } elsif($function eq 'history'){ &history_i; } else { &list_i; } &footer_i; exit; } sub make_salt{ srand(); $xx = "ABCDEFGHIJKLMNOPQRSTUVWXYZ" . "abcdefghijklmnopqrstuvwxyz" . "0123456789."; $salt = substr($xx, int(rand(63)), 1); $salt .= substr($xx, int(rand(63)), 1); $salt .= substr($xx, int(rand(63)), 1); $salt .= substr($xx, int(rand(63)), 1); } sub conv_zenkaku{ for($j=0;$j<17;$j++){ @lev[$j]=~ s/0/0/g; @lev[$j]=~ s/1/1/g; @lev[$j]=~ s/2/2/g; @lev[$j]=~ s/3/3/g; @lev[$j]=~ s/4/4/g; @lev[$j]=~ s/5/5/g; @lev[$j]=~ s/6/6/g; @lev[$j]=~ s/7/7/g; @lev[$j]=~ s/8/8/g; @lev[$j]=~ s/9/9/g; } for($j=0;$j<10;$j++){ @prod[$j]=~ s/0/0/g; @prod[$j]=~ s/1/1/g; @prod[$j]=~ s/2/2/g; @prod[$j]=~ s/3/3/g; @prod[$j]=~ s/4/4/g; @prod[$j]=~ s/5/5/g; @prod[$j]=~ s/6/6/g; @prod[$j]=~ s/7/7/g; @prod[$j]=~ s/8/8/g; @prod[$j]=~ s/9/9/g; } } sub rss_write { if(!open(IN,"$historyfile")){&header; &error_message('datafile error2449','data file access failed.');} @list=; close IN; @list=reverse(@list); $items=""; $item=""; $count=0; foreach $i(@list){ if($count <10){ ($dummy,$rname,$rtitle,$rtime,$rmaxno,$rbody)=split(/\t/,$i); $rbody =~ s/
/\n/g; $rbody =~ s/&/&/g; $rbody =~ s/"/"/g; $rbody =~ s/'/'/g; $rbody =~ s/&lt;/</g; $rbody =~ s/&gt;/>/g; if($dummy eq "DWRITE"){$rstitle="$rtitle : $rname さんの日記[$rmaxno]更新"; $rsource="$rname/diary/$rmaxno"; $link="$site$script?function=prof&name=$rname&mode=$rmaxno"; } if($dummy eq "NEWREG"){$rstitle="$rtitle : $rname さん[$rmaxno]新規登録"; $rsource="$rname/newreg/$rmaxno"; $link="$site$script?function=profdetail&name=$rname"; } if($dummy eq "DMODIF"){$rstitle="$rtitle : $rname さんの日記[$rmaxno]修正"; $rsource="$rname/dmodif/$rmaxno"; $link="$site$script?function=prof&name=$rname&mode=$rmaxno&mod"; } if($dummy eq "PROFED"){$rstitle="$rname さんプロフィール変更"; $rsource="$rname/profed/$rmaxno"; $link="$site$script?function=profdetail&name=$rname"; } if($dummy eq "DERASE"){$rstitle="$rname さんの日記[$rmaxno]が削除"; $rsource="$rname/derase/$rmaxno"; $link="$site$script?function=prof&name=$rname&del"; $rbody="deleted"; } if($dummy eq "RESDIA"){ ($n1,$n2)=split(/ /,$rname); $rstitle="$n2 さんの日記[$rmaxno]に$n1さんがレス"; $rsource="$n1$n2$rtitle/resdia/$rmaxno"; $link="$site$script?function=prof&name=$n2&no=$rmaxno&$rtitle"; } if($dummy eq "MERIED"){$rstitle="$rname さんメリットポイント変更"; $rsource="$rname/profed/$rmaxno"; $link="$site$script?function=profdetail&name=$rname"; } if($dummy eq "CUSTED"){$rstitle="$rname さん$custom_field[0]変更"; $rsource="$rname/profed/$rmaxno"; $link="$site$script?function=profdetail&name=$rname"; } #DWRITE\t$name\t$title\t$rsstime\t$maxno\t$body\t\n #NEWREG\t$name\tNewMember\t$rsstime\t$no\t\t\n #DMODIF\t$name\t$title\t$rsstime\t$no\t$body\t\n #PROFED\t$name\tPROFED\t$rsstime\t$no\t\t\n #DERASE\t$name\t$title\t$rsstime\t$no\t$body\t\n #RESDIA\t$name $name2\t$title\t$rsstime\t$no\t$body\t\n $items .=" \n"; $item .="\n$rstitle\n $link\n $rtitle $rbody\n $rtime\n\n"; } $count++; } if(!open(OUT,">$rdfname")){&header; &error_message('datafile error2422','data file access failed.');} print OUT <<"EOM"; $topic $site$script $rsstime $topic $items $item EOM close OUT; chmod 0666,$rdfname; } sub update_keyword{ $htmlfile="$keydir$keyno\.html"; if(!open(IN,$htmlfile)){&header; &error_message('datafile error2626','data file access failed.');} @html=; close IN; @outhtml=(); foreach $i(@html){ if($i =~ /