Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- REM Start of BASIC! Program
- console.title "マスコットカレンダ起動中..."
- grabfile afl$,"msc.txt",1
- array.delete fk1$[]
- split fk1$[],afl$,"\n"
- array.length lfk1,fk1$[]
- socket.myip ip$
- if ip$="" then
- popup "ネットワーク未接続なので終了します。",0,0,1
- pause 4000
- exit
- else
- popup "ネットワーク接続済",0,0,1
- pause 4000
- endif
- graburl arss$,"http://rss.rssad.jp/rss/mainichi/flash.rss"
- array.delete wk1$[]
- split wk1$[],arss$,"\n"
- array.length lwk1,wk1$[]
- j=1
- p1$=""
- p2$=""
- p3$=""
- p4$=""
- p5$=""
- p6$=""
- p7$=""
- p8$=""
- p9$=""
- p10$=""
- for i=1 to lwk1
- if is_in("<title>",wk1$[i])<>0 then
- out$=replace$(wk1$[i],"<title>","")
- out$=replace$(out$,"</title>","")
- out$=mid$(out$,5)
- if j=1 then
- p1$="☆☆毎日新聞速報☆☆"
- endif
- if j=2 then
- p2$=out$
- endif
- if j=3 then
- p3$=out$
- endif
- if j=4 then
- p4$=out$
- endif
- if j=5 then
- p5$=out$
- endif
- if j=6 then
- p6$=out$
- endif
- if j=7 then
- p7$=out$
- endif
- if j=8 then
- p8$=out$
- endif
- if j=9 then
- p9$=out$
- endif
- if j=10 then
- p10$=out$
- endif
- j=j+1
- endif
- next i
- array.delete wk1$[]
- print p1$
- print p2$
- print p3$
- print p4$
- print p5$
- print p6$
- print p7$
- print p8$
- print p9$
- print p10$
- console.title "画面編集中..."
- grabfile outhtml$,"cal810.htm",1
- nxtcal:
- outhtml$=replace$(outhtml$,"@@@1@@@",p1$)
- outhtml$=replace$(outhtml$,"@@@2@@@",p2$)
- outhtml$=replace$(outhtml$,"@@@3@@@",p3$)
- outhtml$=replace$(outhtml$,"@@@4@@@",p4$)
- outhtml$=replace$(outhtml$,"@@@5@@@",p5$)
- outhtml$=replace$(outhtml$,"@@@6@@@",p6$)
- outhtml$=replace$(outhtml$,"@@@7@@@",p7$)
- outhtml$=replace$(outhtml$,"@@@8@@@",p8$)
- outhtml$=replace$(outhtml$,"@@@9@@@",p9$)
- outhtml$=replace$(outhtml$,"@@@10@@@",p10$)
- isz=420-int(rnd()*20)
- sisz$=replace$(str$(isz),".0","")
- outhtml$=replace$(outhtml$,"@@@sisz@@@",sisz$)
- inm=int(rnd()*lfk1)+1
- if inm>lfk1 then
- inm=lfk1
- endif
- outhtml$=replace$(outhtml$,"@@@11@@@",fk1$[inm])
- console.title "マスコットカレンダ表示"
- cls
- print "カレンダー表示開始"
- nxttest:
- HTML.OPEN
- HTML.LOAD.string outhtml$
- xnextUserAction:
- ! loop until data$ is not ""
- DO
- HTML.GET.DATALINK data$
- UNTIL data$ <> ""
- type$ = LEFT$(data$, 4)
- data$ = MID$(data$,5)
- ! Act on the data type
- ! Shown are all the current data types
- SW.BEGIN type$
- ! Back Key hit.
- ! if we can go back then do it
- SW.CASE "BAK:"
- PRINT "BACK key: " + data$
- popup "終了します",0,0,0
- pause 2000
- exit
- SW.BREAK
- ! A hyperlink was clicked on
- SW.CASE "LNK:"
- PRINT "Hyperlink selected: "+ data$
- popup "終了します",0,0,0
- pause 2000
- exit
- SW.BREAK
- ! An error occured
- SW.CASE "ERR:"
- PRINT "Error: " + data$
- popup "エラーが発生しました 終了します",0,0,0
- pause 2000
- exit
- SW.BREAK
- ! User data returned
- SW.CASE "DAT:"
- PRINT "User data: " + data$
- ! Check for Exit
- IF data$ = "Exit"
- PRINT "User ended demo."
- HTML.CLOSE
- popup "終了します",0,0,0
- pause 5000
- end
- else
- msx$=data$+"←データの内容"
- popup msx$,0,0,0
- html.close
- if data$="//f//" then
- popup "画像ファイルを登録",0,0,0
- grabfile afl$,"msc.txt",1
- text.input kka$,afl$,"画像のURLを1行づつ登録"
- Text.open w, file_num2, "msc.txt"
- msg$="【登録内容】\n"+kka$
- popup msg$,0,0,1
- pause 4000
- text.writeln file_num2,kka$
- text.close file_num2
- pause 1000
- grabfile afl$,"msc.txt",1
- array.delete fk1$[]
- split fk1$[],afl$,"\n"
- array.length lfk1,fk1$[]
- goto nxtcal
- endif
- if data$="//w//" then
- popup "前月のカレンダを表示",0,0,0
- grabfile outhtml$,"cal800.htm",1
- goto nxtcal
- endif
- if data$="//y//" then
- popup "今月のカレンダを表示",0,0,0
- grabfile outhtml$,"cal810.htm",1
- goto nxtcal
- endif
- if data$="//z//" then
- popup "翌月のカレンダを表示",0,0,0
- grabfile outhtml$,"cal820.htm",1
- goto nxtcal
- endif
- pause 4000
- popup "終了します",0,0,0
- exit
- ENDIF
- SW.BREAK
- ! Form data returned.
- ! Note: Form data returning
- ! always exits the html.
- SW.CASE "FOR:"
- PRINT "Form data: "+data$
- popup "終了します",0,0,0
- pause 2000
- exit
- SW.BREAK
- SW.DEFAULT
- PRINT "Unexpected data type:", type$ + data$
- popup "終了します",0,0,0
- pause 2000
- exit
- SW.END
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement