• 02-02-2008, 16:25:20
    #1
    Eposta Aktivasyonu Gerekmekte
    <%
    Function fonkVeriCek(strVeri, strBaslamaEtiket, strBitisEtiket)
    dim intBaslama
     intBaslama = InStr(1, strVeri, strBaslamaEtiket, vbTextCompare)
    if intBaslama then
     intBaslama = intBaslama + Len(strBaslamaEtiket)
     intBitis = InStr(intBaslama + 1, strVeri, strBitisEtiket, vbTextCompare)
     fonkVeriCek = CStr(Mid(strVeri, intBaslama, intBitis - intBaslama))
    else
     fonkVeriCek = " " 
    end if
    End Function
    function fonkXmlHttp(strUrl)
    dim objXmlHttp
    set objXmlHttp = Server.CreateObject("Microsoft.XMLHTTP") 
     objXmlHttp.Open "GET", strUrl, false
     objXmlHttp.SetRequestHeader "Pragma", "no-cache"
     objXmlHttp.SetRequestHeader "Cache-control", "no-cache"
    on error Resume next
     objXmlHttp.Send
    if Err.Number<>0 then
     fonkXmlHttp = ""
    exit function
    end If
    on error Goto 0
    if (objXmlHttp.Status = 200) then
     fonkXmlHttp = objXmlHttp.ResponseText
     fonkXmlHttp = fonkStream(objXmlHttp.ResponseBody,"iso-8859-9") 
    else
     fonkXmlHttp = "Hata : " & objXmlHttp.StatusText
    end if
    end function
    function fonkStream(Veri,KarakterSet)
    dim objStream
    set objStream = Server.CreateObject("ADODB.Stream")
     objStream.Type = 1
     objStream.Mode = 3
     objStream.Open
     objStream.Write Veri
     objStream.Position = 0
     objStream.Type = 2
     objStream.Charset = KarakterSet
     fonkStream = objStream.ReadText 
     objStream.Close
    set objStream = Nothing
    end function
    veri = fonkXmlHttp("http://radyo5.alyasoft.net:8782/")
    veri = Replace(veri, "%", "x")
    veri = Replace(veri, "<HTML><HEAD><meta http-equiv=""Content-Language"" content=""en-us""><meta http-equiv=""Content-Type"" content=""text/html; charset=windows-1252""><meta http-equiv=""Pragma"" content=""no-cache""><meta http-equiv=""Expires"" content=""Mon, 01 Jan 1990 12:00:00 GMT""><title>SHOUTcast Administrator</title><style type=""text/css""><!--a:link {color: blue; font-family:Arial, Helvetica; font-size:9pt;}a:visited {color: blue; font-family:Arial, Helvetica; font-size:9pt;}a:hover {color: red; font-family:Arial, Helvetica; font-size:9pt; }.default {color: White; font-family:Arial, Helvetica; font-size:9pt; font-weight: normal}.ST {color: White; font-family:Arial, Helvetica; font-size:8pt; font-weight: normal}.logoText {color: red; font-family: Arial Black, Helvetica, sans-serif; font-size: 25pt; font-weight: normal; letter-spacing : -2.5px;}.flagText {color: blue; font-family: webdings; font-size: 36pt; font-weight: normal; }.ltv {color: blue; font-family: Arial, Helvetica, sans-serif; font-size: 9pt; font-weight: normal;}.tnl {color: black; font-family: Arial, Helvetica, sans-serif; font-size: 10pt; font-weight: bold; text-decoration: none;}--></style></HEAD><BODY topmargin=0 leftmargin=0 marginheight=0 marginwidth=0 bgcolor=#000000 text=#EEEEEE link=#001155 vlink=#001155 alink=#FF0000><font class=default><table width=100x border=0 cellpadding=0 cellspacing=0><tr><td height=50><font class=flagText>U</font><font class=logoText>&nbsp;SHOUTcast D.N.A.S. Status</font></td></tr><tr><td height=14 align=right><font class=ltv><a id=ltv href=""http://www.shoutcast.com/"">SHOUTcast Server Version 1.9.7/Linux</a></font></td></tr><tr><td bgcolor=#DDDDDD height=20 align=center><table width=100x border=0 cellpadding=0 cellspacing=0><tr><td align=center><font class=tnl><a id=tnl href=""index.html"">Status</a></font></td><td align=center><font class=tnl>&nbsp;|&nbsp;</font></td><td align=center><font class=tnl><a id=tnl href=""played.html"">Song History</a></font></td><td align=center><font class=tnl>&nbsp;|&nbsp;</font></td><td align=center><font class=tnl><a id=tnl href=""listen.pls"">Listen</a></font></td><td align=center><font class=tnl>&nbsp;|&nbsp;</font></td><td align=center><font class=tnl><a id=tnl href=""home.html"">Stream URL</a></font></td><td align=center><font class=tnl>&nbsp;|&nbsp;</font></td><td align=center><font class=tnl><a id=tnl href=""admin.cgi"">Admin Login</a></font></td></tr></table></td></tr></table><br><table cellpadding=5 cellspacing=0 border=0 width=100x><tr><td bgcolor=#000025 colspan=2 align=center><font class=ST>Current Stream Information</font></td></tr></table>", "<style>.default{font-family:verdana; font-size: 7pt;}</style>")
    veri = Replace(veri, "<br><table cellpadding=0 cellspacing=0 border=0 width=100x>    <tr><td bgcolor=#DDDDDD  nowrap colspan=5 align=center><table cellspacing=0 cellpadding=0 border=0><tr><td><font class=ltv>Written by Stephen 'Tag Loomis, Tom Pepper and Justin Frankel</font></td></tr></table></td></tr><tr><td nowrap colspan=5 align=center><font class=ST><b><a href=""http://www.shoutcast.com/disclaimer.phtml"">Copyright Nullsoft Inc</a><a href=""/llamacookie"">.</a> 1998-2004</b></font></td></tr></table></font></body></html>", "")
    veri = Replace(veri, "Server is currently up and public.", "Radyo su an yayinda!")
    veri = Replace(veri, "Stream is up at", "Yayin kalitesi")
    veri = Replace(veri, "with", "<br>Toplam dinleyici")
    veri = Replace(veri, "of", "<br>Toplam kapasite")
    veri = Replace(veri, "listeners", "dinleyici.")
    veri = Replace(veri, " unique", "")
    veri = Replace(veri, "Server Status", "Radyo durumu")
    veri = Replace(veri, "Stream Status", "Yayin durumu")
    veri = Replace(veri, "Listener Peak", "Dinleyici")
    veri = Replace(veri, "Average Listen Time", "Dinlenme süresi")
    veri = Replace(veri, "Stream Title", "Yayin adi")
    veri = Replace(veri, "Content Type", "Icerik")
    veri = Replace(veri, "Stream Genre", "Tür")
    veri = Replace(veri, "Stream URL", "Adres")
    veri = Replace(veri, "Stream ICQ", "ICQ")
    veri = Replace(veri, "Stream AIM", "AIM")
    veri = Replace(veri, "Stream IRC", "IRC")
    veri = Replace(veri, "Current Song", "Calan Sarki")
    veri = Replace(veri, "align=center", "align=left")
    response.write veri
    %>
    Biraz önce bir müşterim için yazdığım kod.. XMLHTTP hakkında bilgiler çok az olduğu için yayınlamak istedim...

    kodları herhangi bir ad ile kaydedin,
    http://radyo5.alyasoft.net:8782/ olan yeri değiştirip kendi radyo sunucunuzun panel adresini yazın, ve kullanın.
    ayrıca replace yaptığım yerdeki <style>.default{font-family:verdana; font-size: 7pt;}</style> kısmı kendinize göre düzenleyebilirsiniz.

    Sorun olursa paylaşın çözelim
  • 02-02-2008, 17:56:35
    #2
    Kodları senn yazdığna emin misin? Frmtr de takılan merrakli diye biri vardı onun hava durumu çekmek için kullandığı ve forumda dağıttı kodlarla harfi harfine aynı da ondan sordum.
  • 02-02-2008, 18:32:45
    #3
    Eposta Aktivasyonu Gerekmekte
    herhangi bir componenti kullanırken kaç farklı şekilde yazabilirsinki kodları.
    bakalım sana farklı bir kullanım göstereyim..
    en basiti..


    <%
    veri = "postlanacakveri"
    Set xmlhttp = Server.CreateObject("Microsoft.XMLHTTP" )
    xmlhttp.Open "POST" , "http://www.google.com.tr", FALSE
    xmlhttp.setRequestHeader "Content-Type", "application/x-www-form-urlencoded"
    xmlhttp.send veri
    xmlhttptext = xmlhttp.Responsetext
    SET xmlhttp = Nothing
    response.write xmlhttptext
    %>


    veya get ile



    <%
    Set xmlhttp = Server.CreateObject("Microsoft.XMLHTTP" )
    xmlhttp.Open "GET" , "http://www.google.com.tr", FALSE
    on error Resume next
    xmlhttp.Send
    if Err.Number<>0 then
    xmlhttptext= ""
    SET xmlhttp = Nothing
    response.write xmlhttptext
    %>
    çıktı almadan önce replace ile adam edersin kodları olur biter...
  • 02-02-2008, 19:50:34
    #4
    Ben kodlardan bahsetmedim ki değişkenlere verdiğin isimlerden bahsettim.
    Hem bişey ispatlamak zorunda değilsn amacım seni zan altında bırakmak falan değil
  • 02-02-2008, 20:22:04
    #5
    SH.ASP diye bir bileşen yazmıştım.XML.HTTP ile ilgili bilgisi olmayanlar bu bileşeni kllanabilirler.Bunu forumda da yazmıştım.Googledan aratarak indirebilirsiniz.

    Kolay Gelsin.
  • 05-02-2008, 01:06:51
    #6
    Eposta Aktivasyonu Gerekmekte
    cortes,
    acaba sayfaya girip sadece linkleri alan bir yöntem varmı?
    1 link değil, sayısı belli olmayan linkler
    hatta <a href="linkim">LINKADI</a> LINKADI nı verebilecek?
    tabiiki sayfada kaçtane link olduğunu bilmiyoruz?
  • 05-02-2008, 16:07:03
    #7
    Elimde birtane spider var.Onda o özellik var fakat şu anda şehir dışındayım.Bilgisayarımın başına geçince buraya indirme linkini veririm.
  • 05-02-2008, 19:16:52
    #8
    Eposta Aktivasyonu Gerekmekte
    ok sevinirim. asp konusunda biraz cılız kaldı bu tarz siteler, asp spider örnekleri çoğalırsa çalışmalarda çoğalır. spider xmlhttp mi kullanıyor başka componentmi?
  • 06-02-2008, 19:24:58
    #9
    O spiderı bende görmek istiyorum Cortes bi zahmet PM ile haber verirsen sevinirim...