HSPポータル
サイトマップ お問い合わせ


HSPTV!掲示板


未解決 解決 停止 削除要請

2013
1205
ゆとりサイトにあるinput欄の文字取得4未解決


ゆとり

リンク

2013/12/5(Thu) 18:32:07|NO.58590

15qm.com/?act=sevin&inm=dil
このサイトは無料メールアドレス作成サイトなんですが
作成されたinput欄のメールアドレスを取得し
mes でexeに表示したいのですが可能ですか?



この記事に返信する


名無し

リンク

2013/12/5(Thu) 19:15:18|NO.58596


#module HSPhtml #uselib "hspsock.dll" #func sockopen sockopen 4 #func sockclose sockclose 0 #func sockget sockget 1 #func sockgetc sockgetc 1 #func sockput sockput 6 #func sockputc sockputc 2 #func sockmake sockmake $10 #func sockgetb sockgetb 1 #func sockputb sockputb 1 #func ipget ipget $10 #func sockcheck sockcheck 0 #func sockwait sockwait $10 #func sockbye sockbye $100 ;---------------------------------------------------------------------- #defcfunc gethtml str p1 , int p2 *modoru sdim buf,1024*1024 sdim buf2,1024*1024 url=p1 TimeOut=p2 if フラグ=0:sdim buf,1024*1024:sdim buf2,1024*1024 フラグ=1 seek = instr(url,0,"http://") seek = 7 getstr host,url,seek,'/' seek = seek+strsize-1 rdir = strmid(url,seek,1024) size = strlen(rdir) sockopen 0,host,80 if stat!0 : sockclose 0 :await 1000: goto*modoru sockput "GET http://"+host+rdir+" HTTP/1.0\nHost: "+host+"\nUser-Agent: HSP PaoProject\n\n",0 ;HEAD GET if stat!0 : sockclose 0 :await 1000: goto*modoru ;---------------------------------------------------------------------- repeat TimeOut sockcheck 0 st=stat if st=0 { sockgetb buf2,0,1024*1024,0 size = stat if size=0 :ct=cnt: break buf = buf+strmid(buf2,0,size) //buf2に終端文字は書き込まれないので受信したバイト数で文字列を取り出す //continue 0 }else{ if st=2 {break} } await 1 loop sockclose 0 stat値=0 if st { if st=1 {stat値=-1} if st=2 {stat値=-2} } sockclose 0 if stat値=0:mref ct2,64:ct2=ct if stat値!0:mref ct2,64:ct2=stat値 return buf #global
htmlを取得するソースコードです。

buf=gethtml(url,TimeOut)//サンプル



名無し

リンク

2013/12/5(Thu) 19:15:45|NO.58597

訂正。

htmlを取得するソースコードです。✖
htmlを取得するモジュールです。○



ゆとり

リンク

2013/12/5(Thu) 20:15:42|NO.58600

解答ありがとうございますw

実行してみたところ
buf=gethtml(url,TimeOut)//サンプル
がパラメーター式の記述が無効です
のエラーがでてしまいます><



なたで

リンク

2013/12/8(Sun) 13:36:01|NO.58645

DOMを使用すると簡単です。
「DOM 講座」とかで検索すると出てきます。


#module #defcfunc getQuickMail local ie, local doc,local a, local b, local c, local d newcom ie,"InternetExplorer.Application" ie -> "Navigate" "http://15qm.com/?act=sevin&inm=dil" repeat await 1 if(ie("Busy")==0){ break } loop doc = ie("Document") a = doc("getElementById", "get") b = a("getElementsByTagName", "input") c = b("item", 0) d = c("value") delcom c delcom b delcom a delcom doc delcom ie return d #global mes getQuickMail()



ONION software Copyright 1997-2023(c) All rights reserved.