/*
NemuList AutomaticCreating Program Ver1.0
*/
//BaseAdd="http://www.bc.wakwak.com/~cosa/";
BaseAdd="http://127.0.0.1/~tukimi/hello2/";
OffLineBaseAdd='C:/www/tukimi/public_html/hello2/';
DiaryNumber=2;
StartYear =1999;
StartMonth=10;
DiaryFolder="diary";
NowDiaryFile="diary.html";
HtmlFileExtension=".html";
MainSubstance='
';
MainListTag='
';
MainListSelectedTag='- ';
ChildrenListTag='
';
ChildrenListSelectedTag='- ';
GrandchildListTag='
';
GrandchildListSelectedTag='- ';
NemuNumber=9;
Nemu=new Array(NemuNumber);
Nemu[0]=new Array( 'home.html',
'HOME',
'TOPに戻ります',
'Not'
);
Nemu[1]=new Array( 'profile.html',
'PROFILE',
'僕のちょっとした自己紹介です',
'ChildrenList','Yes',
'名前=name,性別=sex,年齢=age',
'aa/name.html,#sex,#old'
);
Nemu[2]=new Array( 'diary.html',
'DIARY',
'毎日つけています(はきっリいってつまらないです((((((^_^;)',
'Diary'
);
Nemu[3]=new Array( 'http://127.0.0.1/~tukimi/hello2/bbs.html',
'SCRIBBL BBS',
'何でも書き込んで!',
'Not'
);
Nemu[4]=new Array( 'cgi/oekakibbs/oekaki.cgi',
'GRFFITO PIAZZA',
'お絵かき掲示板です。お好きな絵を描いて下さいませ',
'Cgi',
'oekaki.cgi?mode=pageview&page=,?mode=pageview&page='
);
Nemu[5]=new Array( 'http://www.hello.co.jp/php/log.phtml?user=ohtsuki',
'VISITOR',
'このページに来てくれた人です(Helloユーザーのみ)',
'Not'
);
Nemu[6]=new Array( 'whats_new.html',
'What’s New',
'このページの更新記録です',
'GrandchildList','3',
'No/Yes,1999年,other/whats_new/whats_new99.html',
'1月;2月;3月;4月;5月,aa/name.html;#2;#3;#4;#5',
'Yes/No,2000年,other/whats_new/whats_new00.html',
'6月;7月;8月;9月;10月;11月,#6;#7;#8;#9;#10;#11',
'No/Yes,2001年,whats_new.html',
'0月;2月;3月;4月;5月,#0;#2;#3;#4;#5'
);
Nemu[7]=new Array( 'link/link01.html',
'LINK',
'リンク集です',
'Not'
);
Nemu[8]=new Array( 'mailto:tsukimi@to-sen.net',
'MAIL',
'管理人(月見)にメールが送れます',
'Not'
);
NemuAdd=window.location.pathname;
SecondLetter=NowDiaryFile.slice(0,2);
BaseDiaryAdd=BaseAdd+DiaryFolder+'/';
BaseAddBlame=BaseAdd;
BaseAddBlame2=BaseAdd;
BaseDiaryAddBlame=BaseDiaryAdd;
if(window.navigator.onLine)
{
M=0;
NemuName=NemuAdd.split("/");
}else{
M=-1;
BaseAdd="file:///"+OffLineBaseAdd;
NemuName=NemuAdd.split("\\");
};
for(A=M;BaseAddBlame2.indexOf("/") != -1;A++)
{
BaseAddBlame2=BaseAddBlame2.replace("/","?");
};
for(B=M+1;BaseDiaryAddBlame.indexOf("/") != -1;B++)
{
BaseDiaryAddBlame=BaseDiaryAddBlame.replace("/","?");
};
MonthDepth=A;
NowMonthDepth=A-(B-A);
for(B in Nemu)
{
switch(Nemu[B][3])
{
case "ChildrenList":
Nemu[B][5]=Nemu[B][5].split(",");
Nemu[B][6]=Nemu[B][6].split(",");
break;
case "Cgi":
Nemu[B][4]=Nemu[B][4].split(",");
Nemu[B][4][0]=Nemu[B][4][0].replace("&","&");
Nemu[B][4][1]=Nemu[B][4][1].replace("&","&");
break;
case "GrandchildList":
Count=1;
for(F=1;Count<=Nemu[B][4];F+=2)
{
Nemu[B][(4+F)]=Nemu[B][(4+F)].split(",");
Nemu[B][(4+F)][0]=Nemu[B][(4+F)][0].split("/");
Nemu[B][(4+F)][1]=Nemu[B][(4+F)][1].split(",");
Nemu[B][(4+F+1)]=Nemu[B][(4+F+1)].split(",");
Nemu[B][(4+F+1)][0]=Nemu[B][(4+F+1)][0].split(";");
Nemu[B][(4+F+1)][1]=Nemu[B][(4+F+1)][1].split(";");
Count++;
};
break;
};
};
document.write(MainSubstance);
document.write(MainListTag);
MainLoop:
for(D=0;D= 1)
{
ListCgi();
};
continue MainLoop;
};
break;
case "ChildrenList":
for(J in Nemu[D][6])
{
ChildrenListAdd =FullAdd+Nemu[D][6][J];
ChildrenListAdd2=BaseAdd+Nemu[D][6][J];
if(FullAdd == location || ChildrenListAdd == location || ChildrenListAdd2 == location)
{
MainListSelected();
ChildrenList();
continue MainLoop;
};
};
break;
case "GrandchildList":
Count =1;
Loop1:
for(G=1;Count<=Nemu[D][4];G+=2)
{
GrandchildAdd=BaseAdd+Nemu[D][(4+G)][2];
for(K in Nemu[D][(4+G)+1][1])
{
GrandchildAdd2=GrandchildAdd+Nemu[D][(4+G)+1][1][K];
GrandchildAdd3=BaseAdd+Nemu[D][(4+G)+1][1][K];
if(GrandchildAdd == location || GrandchildAdd2 == location || GrandchildAdd3 == location)
{
MainListSelected();
GrandchildList();
continue MainLoop;
continue Loop1;
};
};
Count++;
};
break;
case "Diary":
if(NemuName[NowMonthDepth] == DiaryFolder || NemuName[NowMonthDepth] == NowDiaryFile)
{
MainListSelected();
DiaryList();
continue MainLoop;
};
break;
case "Not":
if(FullAdd == location)
{
MainListSelected();
continue MainLoop;
};
break;
};
if(ReferenceAdd == 0 || ReferenceMail == 0)
{
BaseAdd="";
}else{
BaseAdd=BaseAddBlame;
};
document.write('
- '+Nemu[D][1]+'
');
};
document.write('
');
document.write('
');
function MainListSelected()
{
document.write(MainListSelectedTag+Nemu[D][1]+'');
};
function GrandchildList()
{
document.write(ChildrenListTag);
Count=1;
Loop:
for(H=1;Count<=Nemu[D][4];H+=2)
{
GrandchildAdd=BaseAdd+Nemu[D][(4+H)][2];
for(L in Nemu[D][(4+H)+1][1])
{
GrandchildAdd2=BaseAdd+Nemu[D][(4+H)][2]+Nemu[D][(4+H)+1][1][L];
GrandchildAdd3=BaseAdd+Nemu[D][(4+H)+1][1][L];
if(GrandchildAdd == location || GrandchildAdd2 == location || GrandchildAdd3 == location)
{
document.write(ChildrenListSelectedTag+Nemu[D][(4+H)][1]+'');
document.write(GrandchildListTag);
for(I in Nemu[D][(4+H)+1][0])
{
if(BaseAdd+Nemu[D][(4+H)+1][1][I] == location)
{
document.write(GrandchildListSelectedTag+Nemu[D][(4+H)+1][0][I]+'');
continue;
};
if(Nemu[D][(4+H)+1][1][I].indexOf('#') == -1)
{
document.write(GrandchildListSelectedTag+''+Nemu[D][(4+H)+1][0][I]+'');
}else{
document.write(GrandchildListSelectedTag+''+Nemu[D][(4+H)+1][0][I]+'');
};
};
document.write('');
Count++;
continue Loop;
};
};
document.write(''+Nemu[D][(4+H)][1]+'');
Count++;
};
document.write('');
};
function ListCgi()
{
document.write(ChildrenListTag);
for(F=1;F');
continue;
};
if(F == CgiPageMax){break;};
document.write('Page'+F+'');
};
document.write('');
};
function ChildrenList()
{
document.write(ChildrenListTag);
for(E1 in Nemu[D][5])
{
if(BaseAdd+Nemu[D][6][E1] == location)
{
document.write(ChildrenListSelectedTag+Nemu[D][5][E1]+'');
continue;
};
if(Nemu[D][6][E1].indexOf('#') == -1)
{
document.write(''+Nemu[D][5][E1]+'');
}else{
document.write(''+Nemu[D][5][E1]+'');
};
};
document.write('');
};
function DiaryList()
{
YY=new Date().getFullYear();
MM=new Date().getMonth()+1;
DD=new Date().getDate();
RemainYear=YY-StartYear;
if(StartMonth<10){StartMonth="0"+StartMonth;};
B1=0;
C1=0;
if(NemuName[NowMonthDepth] != NowDiaryFile)
{
Depth=MonthDepth;
}else{
Depth=NowMonthDepth;
};
NowPageMonth=NemuName[Depth].substring(0,2);
NowPageYear =NemuName[Depth-1];
if(NowPageYear == YY || NowPageMonth == SecondLetter)
{
WriteNowYear();
}else if(NowPageYear == StartYear)
{
WriteStartYear();
}else{
WriteYear();
};
function WriteNowYear()
{
document.write(ChildrenListTag);
for(D1=0;D1'+(StartYear+D1)+'年')
}else{
document.write(''+(StartYear+D1)+'年');
};
};
document.write(ChildrenListSelectedTag+YY+'年');
document.write(GrandchildListTag);
for(A1=1;A1<=MM;A1++)
{
ListStream();
if(DD <= 1 && A1 == MM-1){A1++;};
if(NowPageMonth == SecondLetter && A1 == MM)
{
document.write(GrandchildListSelectedTag+B1+'月');
break;
};
if(B1 == MM)
{
DepthDifference=MonthDepth-NowMonthDepth
DepthUp="";
for(H1=1;H1 <= DepthDifference;H1++)
{
DepthUp=DepthUp+"../";
};
C1=DepthUp+DiaryFolder;
};
if(C1 < 10){C1="0"+C1;};
document.write(''+B1+'月');
};
document.write('');
};
function WriteYear()
{
NowPageOldYear=NowPageYear-StartYear;
NowPageNewYear=YY-NowPageYear;
document.write(ChildrenListTag);
for(D1=0;D1'+(StartYear+D1)+'年')
}else{
document.write(''+(StartYear+D1)+'年');};
};
document.write(ChildrenListSelectedTag+NowPageYear+'年');
document.write(GrandchildListTag);
for(A1=1;A1<=12;A1++)
{
ListStream();
if(A1 == 13){break;};
if(C1 < 10){C1="0"+C1;};
document.write(''+B1+'月');
};
document.write('');
for(D1=1;D1<=NowPageNewYear;D1++)
{
document.write(''+(Number(NowPageYear)+D1)+'年');
};
};
function WriteStartYear()
{
document.write(ChildrenListTag);
document.write(ChildrenListSelectedTag+NowPageYear+'年');
document.write(GrandchildListTag);
B1=StartMonth-1;
C1=StartMonth-1;
for(A1=StartMonth;A1<=12;A1++)
{
ListStream();
if(A1 == 13){break;};
if(C1 < 10){C1="0"+C1;};
document.write(''+B1+'月');
};
document.write('');
for(D1=1;D1<=RemainYear;D1++)
{
document.write(''+(StartYear+D1)+'年')
};
};
function ListStream()
{
B1++;
C1++;
if(NowPageMonth == A1)
{
document.write(GrandchildListSelectedTag+B1+'月');
A1++;
B1++;
C1++;
};
};
document.write('');
};