´ç½Å¿¡°Ô·Î ¶°³ª´Â ²Þ¼Ó¿©Çà - ²Þ¼Ó³ª¶ó(http://www.inyourdream.net) ÀÔ±¹Çϱâ | ¿µÁÖ±Ç ½Åû
  • ¸öºÎ¸² °ñ¶ó°ñ¶ó
  • ¼Ò±Ù¼Ò±Ù
  • µµ¶õµµ¶õ
  • ³«¼­¸¶´ç
  • Âø°¢ÇѾÆÀÌ
  • ¼ýÀÚ¸ÂÃß±â
  • ¼Ò¿øºô±â
  • ÈçÀû³²±â±â
  • ²Þ¼Ó¿©Çà
  • Ä£±¸Áý ³î·¯°¡±â
  • ¸ðµÎµå¸²´ÔÀÇ È¨
  • î¤éÞ´ÔÀÇ È¨
  • Çö¿ì´ÔÀÇ È¨
  • º°¾ÆÇØ´ÔÀÇ È¨
  • ÇÞ»ì´ÔÀÇ È¨
  • À̳ª´Ï´ÔÀÇ È¨
  • À¯¸®¾Ë´ÔÀÇ È¨
  • ³È³ÈÀÌ´ÔÀÇ È¨
  • ²ÀÁö´ÔÀÇ È¨
  • ´ë¼º´ÔÀÇ È¨
  • Çѽº / 2001-06-10 / ¿ÀÀü 2:28:26 / 203.228.58.245
    Á¶È¸¼ö : 151
    [Áú¹®] golbal »ç¿ëÁß ¹æ¹®ÀÚ ÇÕ°è°¡ ¾ÈµÇ³»¿ä! µµ¿ÍÁÖ¼¼¿ä^^
    ¾Æ·¡ ¼Ò½ºÀä
    ±²ÀåÈ÷ º¹ÀâÇØ¿©,,,,,
    ¿©±âÀú±â ÇÁ·Î±×·¥À» ½â¾î¼­ »ç¿ëÇÏ´Ùº¸´Ï....
    µÚ ½âÀÎ°Í °°¾Æ¿©~
    golbal »ç¿ëÁß ÇöÀçÁ¢¼ÓÀÚ,¿À´ÃÁ¢¼ÓÀÚ´Â µÇ´Âµ¥ ÀüüÁ¢¼ÓÀÚ ÇÕ°è°¡ ¾ÈµÇ³»¿ä ¹¹°¡ À߸øµÈ´ÂÁö À߸𸣰ھ.
    µÎ¹ø°´Â¿ä.
    Application("AdminPass") = "kcm7777" À̺κÐÀÌ µÇÁö¸¦ ¾È´Â°Í °°¾Æ¿©~ À§Ä¡°¡ À߸øµÈ³ª¿©,,,,,,???
    ºÎŹµå¸³´Ï´Ù!

    global.asa°¡ »çÀÌÆ®¸ÞÀοܿ¡ »ç¿ëÇϴ¹æ¹ýµµ ÀÖ´Ù´øµ¥ ±×°É ¾î¶»°Ô ¼³Á¤ÇÏ´ÂÁöµµ Á» °¡¸£ÃÄÁÖ½Ã¸é °¨»çÇÏ°Ú½À´Ï´Ù.


    ¼Ò½ºÀÔ´Ï´Ù!
    <SCRIPT LANGUAGE="VBScript" RUNAT="Server">

    Sub Application_OnStart

    End Sub


    Sub Application_OnEnd

    End sub


    Sub Session_OnStart

    ' SessionÀÇ À¯Áö °ªÀ» ¼³Á¤ÇÑ´Ù
    Session.TimeOut = 20

    Application("AdminPass") = "7777"

    ' WebZip,Teleport,NamoWebEditor,GetRight,WebFetch·Î ºÎÅÍ Á¢±ÙÇϴ°ÍÀ» ¸·´Â´Ù
    V_IP = Request.ServerVariables("Remote_Addr")
    V_Agent = Request.ServerVariables("HTTP_USER_AGENT")

    If InStr(V_Agent, "WebZIP") Then
    Response.Redirect "http://" & V_IP
    Elseif InStr(V_Agent, "Teleport") Then
    Response.Redirect "http://" & V_IP
    Elseif InStr(V_Agent, "NamoWebEditor") Then
    Response.Redirect "http://" & V_IP
    Elseif InStr(V_Agent, "GetRight") Then
    Response.Redirect "http://" & V_IP
    Elseif InStr(V_Agent, "WebFetch") Then
    Response.Redirect "http://" & V_IP
    End If

    Application.Lock

    Set DbCon=Server.CreateObject("ADODB.Connection")
    DbCon.Open("DSN=sss;UID=sa;PWD=1234")

    ' ·Î±×Á¤º¸ÀÇ Key°ªÀ» »ý¼ºÇÏ´Â ·çƾ
    Sec = Second(time)
    If Cint(Sec) < 10 Then
    Key = StrReverse(Session.SessionID & "0" & Sec)
    Else
    Key = StrReverse(Session.SessionID & Sec)
    End If

    ' ·Î±×Á¤º¸¸¦ ³²±â´Â ·çƾ
    'SQL = "Insert into user_logs values "
    'SQL = SQL & "('" & Key & "','" & Now() & "','" & Now() & "','" & Request.ServerVariables("REMOTE_HOST") & "')"
    'DbCon.Execute(SQL)

    ' Á¢¼Ó Åë°è¸¦ À§ÇÑ ·çƾ±¸¼º
    code = "home"
    vDate = trim(cstr(date())) 'ÇöÀç ½Ã½ºÅÛ ³¯Â¥ (99/04/02)
    vYear = trim(cstr(year(date))) '½Ã½ºÅÛ ³âµµ (1999)
    vMonth = trim(cstr(month(date))) '½Ã½ºÅÛ ¿ù (4)
    vDay = trim(cstr(day(date))) '½Ã½ºÅÛ ÀÏ(2)
    vTime = trim(cstr(hour(time))) '½Ã½ºÅÛ ½Ã°£ (15)
    vWeek = trim(cstr(weekday(date))) '½Ã½ºÅÛ ¿äÀÏ°ª(6)

    ' Conn_Stat Å×ÀÌºí¿¡ °ªÀÌ ÀÖ´ÂÁö ¾ø´ÂÁö üũÇÏ°í, °ªÀÌ ÀÖÀ» °æ¿ì ÇØ´ç ÄÚµåÀÇ ÃÖÃÊ, ÃÖ±Ù Number°ª Àд´Ù
    SQL = "SELECT Count(number),Max(number),Min(number) FROM conn_statistics WHERE code = '" & code & "'"
    Set lscheck1 = DbCon.Execute(SQL)

    If lscheck1(0) <> 0 Then 'Ãʱâ Å×À̺íÀÌ Á¸ÀçÇÑ´Ù¸é
    mnum = cint(lscheck1(1)) '°¡Àå ÃÖ±Ù ±â·ÏµÈ ·¹ÄÚµå ³Ñ¹ö
    snum = cint(lscheck1(2)) 'ÃÖÃÊ ±â·ÏµÈ ·¹ÄÚµå ³Ñ¹ö

    ' °¡Àå ÃÖ±Ù ±â·ÏµÈ ·¹ÄÚµåÀÇ Çʵ尪À» ÀоîµéÀÓ
    SQL = "SELECT * FROM conn_statistics WHERE code = '" & code & "' and number=" & lscheck1(1) & " "
    Set lsyear = DbCon.Execute(SQL)

    ddate = trim(cstr(lsyear("vdate")))
    dyear = trim(cstr(lsyear("vyear")))
    dmonth = trim(cstr(lsyear("vmonth")))
    dday = trim(cstr(lsyear("vday")))
    dtime = trim(cstr(lsyear("vtime")))
    tvisit = cint(lsyear("tvisit"))
    dvisit = cint(lsyear("dvisit"))
    mvisit = cint(lsyear("mvisit"))
    wvisit = cint(lsyear("wvisit"))

    If (ddate = vDate and dtime = vTime) Then '¸¸¾à ÃÖ±Ù ·¹ÄÚµå °ªÀÌ ¿À´Ã ³¯Â¥ ÇöÀç½Ã°£ÀÎ °æ¿ì
    'Àüü Á¢¼Ó ¼ö 1 Áõ°¡
    SQL = "UPDATE conn_statistics SET avisit=avisit+1 WHERE code='" & code & "' and number=" & snum & " "
    Set rsupta = DbCon.Execute(SQL)

    '½Ã°£, ÀÏ, ¿ù, ¿äÀÏ Á¢¼Ó ¼ö 1¾¿ Áõ°¡
    SQL = "UPDATE conn_statistics SET "
    SQL = SQL & "tvisit=tvisit+1,dvisit=dvisit+1,mvisit=mvisit+1,wvisit=wvisit+1 WHERE number=" & mnum & " "
    Set rsupt = DbCon.Execute(SQL)
    Else '¿À´Ã ³¯Â¥ ÇöÀç½Ã°£ÀÌ ¾Æ´Ï¶ó¸é
    If (dyear = vYear and dmonth = vMonth and dday = vDay) Then '¿À´Ã ³¯Â¥Àΰ¡¸¦ üũÇؼ­ ¿À´Ã ³¯Â¥À̸éÀº
    'ÇöÀç ½Ã°£°ªÀ¸·Î Ãß°¡Çؼ­ »õ·Î ·¹ÄÚµå ÀÛ¼º
    dvisit = cint(dvisit)+1 'ÀÏ ÀüüÁ¢¼Ó¼ö + 1
    mvisit = cint(mvisit)+1 '¿ù ÀüüÁ¢¼Ó ¼ö + 1
    wvisit = cint(wvisit)+1 '¿ùº° ÁÖ ÃÖ´ë°ª + 1

    'Àüü Á¢¼Ó¼ö 1 Áõ°¡
    SQL = "UPDATE conn_statistics SET avisit=avisit+1 WHERE code='" & code & "' and number=" & snum & " "
    Set rsupta = DbCon.Execute(SQL)
    'ÇöÀç ³¯Â¥¿¡ ÇöÀç½Ã°£À¸·Î »õ·Î¿î ·¹ÄÚµå Ãß°¡
    SQL = "INSERT INTO conn_statistics(code,vdate,vyear,vmonth,vday,vtime,vweek,tvisit,dvisit,mvisit,wvisit,avisit) " & _
    "VALUES ('"&code&"','"&vDate&"','"&vYear&"','"&vMonth&"','"&vDay&"','"&vTime&"','"&vWeek&"',1,"&dvisit&","&mvisit&","&wvisit&",0)"
    Set lsint = DbCon.Execute(SQL)
    Else '¿À´Ã ³¯Â¥°¡ ¾Æ´Ï¶ó¸é
    If (dyear = vYear and dmonth = vMonth) Then 'ÇöÀçÀÇ ´ÞÇÏ°í °°Àº°¡ üũÇÏ°í ³­ ÈÄ ÇöÀç ´Þ ÇÏ°í °°´Ù¸é
    'ÇöÀç ³¯Â¥¸¦ Ãß°¡Çؼ­ »õ·Î ·¹ÄÚµå ÀÛ¼º
    SQL = "SELECT Count(wvisit),Max(wvisit) FROM conn_statistics WHERE code='" & code & "'"
    SQL = SQL & " and vyear='" & vYear & "' and vmonth='" & vMonth & "' and vweek='" & vWeek & "'"
    Set lscw = DbCon.Execute(SQL)

    '¿äÀÏ °ªÀÌ ¾øÀ» °æ¿ì ¿¡·¯°¡ ¹ß»ýÇϹǷÎ
    If lscw(0) = "0" Then 'ÇØ´ç ¿ù¿¡ ÇØ´ç ¿äÀÏÀÇ °ªÀÌ ¾ø´Ù¸é
    mwvisit = 1 '±× ¿äÀÏÀÇ Á¢¼Ó °ªÀ» 1·Î
    Else
    mwvisit = cint(lscw(0)) + 1 'ÀÌ¹Ì ÇØ´ç¿äÀÏÀÇ °ªÀÌ ÀÖ´Ù¸é 1 Áõ°¡
    End If

    mvisit = cint(mvisit) + 1 '¿ù Àüü Á¢¼Ó¼ö +1

    'ÇöÀç ³¯Â¥ÀÇ »õ·Î¿î ·¹ÄÚµå Ãß°¡
    SQL = "INSERT INTO conn_statistics(code,vdate,vyear,vmonth,vday,vtime,vweek,tvisit,dvisit,mvisit,wvisit,avisit) " & _
    "VALUES ('"&code&"','"&vDate&"','"&vYear&"','"&vMonth&"','"&vDay&"','"&vTime&"','"&vWeek&"',1,1,"&mvisit&","&mwvisit&",0)"
    Set lsind = DbCon.Execute(SQL)

    'Àüü Á¢¼Ó¼ö 1 Áõ°¡
    SQL = "UPDATE conn_statistics SET avisit=avisit+1 WHERE code='" & code & "' and number=" & snum & " "
    Set rsupta = DbCon.Execute(SQL)

    Else 'ÇöÀçÀÇ ´ÞÀÌ ¾Æ´Ï¶ó¸é
    If dyear = vYear Then '¿ÃÇØÀΰ¡¸¦ üũÇÏ°í ³­ ÈÄ ¿ÃÇØÀ̸é
    'ÇöÀçÀÇ ´ÞÀ» Ãß°¡Çؼ­ »õ·Î ·¹ÄÚµå ÀÛ¼º
    SQL = "INSERT INTO conn_statistics(code,vdate,vyear,vmonth,vday,vtime,vweek,tvisit,dvisit,mvisit,wvisit,avisit) " & _
    "VALUES ('"&code&"','"&vDate&"','"&vYear&"','"&vMonth&"','"&vDay&"','"&vTime&"','"&vWeek&"',1,1,1,1,0)"
    Set lsinm = DbCon.Execute(SQL)

    'ÀüüÁ¢¼Ó¼ö 1 Áõ°¡
    SQL = "UPDATE conn_statistics SET avisit=avisit+1 WHERE code='" & code & "' and number=" & snum & " "
    Set rsupta = DbCon.Execute(SQL)
    End If
    End If
    End If
    End If
    Else
    ' conn_statistics Å×À̺íÀ» »ý¼ºÇÏ°í ÃʱⰪ ÀÔ·Â

    'SQL = "insert into conn_statistics(code,vdate,vyear,vmonth,vday,vtime,vweek,tvisit,dvisit,mvisit,wvisit,avisit) " & _
    '" values ('"&code&"','"&vDate&"','"&vYear&"','"&vMonth&"','"&vDay&"','"&vTime&"','"&vWeek&"',1,1,1,1,1) "
    'Set lsyearin = DbCon.Execute(SQL)
    End If
    Application.UnLock

    End Sub

    Sub Session_OnEnd

    Application.Lock

    Set DbCon=Server.CreateObject("ADODB.Connection")
    DbCon.Open("DSN=sss;UID=sa;PWD=1234")

    SQL = "UPDATE user_logs SET log_out='"&Now()&"' where SubString(log_id,3,10)='"&StrReverse(Session.SessionID)& "'"
    DbCon.Execute(SQL)
    SQL = "Delete from temp_buy where SubString(temp_id,3,10) ='" & StrReverse(Session.SessionID) & "'"
    DbCon.Execute(SQL)
    Application.UnLock

    End Sub
    </SCRIPT>


    <SCRIPT LANGUAGE="VBscript" RUNAT=Server>
    Sub Session_OnStart

    Application.lock
    ' ÇÑ SessionÀÇ Ã³¸®°¡ ³¡³¯ ¶§±îÁö ´Ù¸¥ Session¿¡ ÀÇÇÑ °£¼·À¸·Î »ý±æ ¼ö ÀÖ´Â
    ' ¿À·ù¸¦ Â÷´ÜÇϱâÀ§ÇØ ApplicationÀ» Àá±Ù´Ù.

    'ÇöÀç ¹æ¹®ÀÚ¼ö Áõ°¡ ½ÃÀÛ
    ' if Not IsNumeric(Application("NowVisitor")) then
    ' Application("NowVisitor")= 1
    ' end if

    Application("NowVisitor") = Application("NowVisitor") + 1

    'ÇöÀç ¹æ¹®ÀÚ¼ö Áõ°¡ ³¡

    Set FileObject = Server.CreateObject("Scripting.FileSystemObject")

    ' ´©Àû ¹æ¹®ÀÚ Ä«¿îÆ®
    On Error Resume Next

    VisitorsPath = Application("ServerPath") + "/Visitors/Visitors.dat"

    Set ObjVisitor = FileObject.OpenTextFile (VisitorsPath)
    visitors = ObjVisitor.ReadLine

    If len(visitors)=0 Then
    visitors=1
    Else
    visitors=Cint(visitors)+1
    End If

    Set ObjVisitor = Nothing

    Set ObjVisitor = FileObject.CreateTextFile (VisitorsPath, TRUE, FALSE)
    ObjVisitor.lock
    ObjVisitor.WriteLine(visitors)
    ObjVisitor.unlock

    Application("Visitors") = visitors

    Set ObjVisitor = Nothing
    ' ´©Àû ¹æ¹®ÀÚ Ä«¿îÆ® ³¡

    ' ¿À´Ã ¹æ¹®ÀÚ Ä«¿îÆ®
    TodayVisitorsPath = Application("ServerPath") + "/Visitors/TodayVisitors.dat"

    Set ObjVisitor = FileObject.OpenTextFile (TodayVisitorsPath)
    Today = CDate(ObjVisitor.ReadLine)
    TodayVisitors = Cint(ObjVisitor.ReadLine)

    if Today <> Date() then ' ¿À´Ã ¹æ¹®ÀÚÀÇ Ä«¿îÆ® ¶§ ³¯Â¥°¡ »õ·Ó°Ô ¹Ù²î¸é ÃʱâÈ­ÇÑ´Ù.

    ' ¿À´Ã ¹æ¹®ÀÚ Á¤º¸¸¦ ±â·ÏÇÒ ÆÄÀÏ»ý¼º
    AppVisitorsPath = Application("ServerPath") + "/Visitors/"+Cstr(date())+".dat"

    Set ObjPreVisitor = FileObject.CreateTextFile (AppVisitorsPath, TRUE, FALSE)

    ObjPreVisitor.lock

    ObjPreVisitor.WriteLine("ÃÑ---¿À´Ã---20ºÐ--- ³¯Â¥/½Ã°£ --- Host Info --- SessionID --- Browser Info")

    ObjPreVisitor.unlock

    Set ObjPreVisitor = Nothing
    ' ¿À´Ã ¹æ¹®ÀÚ Á¤º¸¸¦ ±â·ÏÇÒ ÆÄÀÏ»ý¼º ³¡

    Today = Date()
    TodayVisitors = 0

    end if

    TodayVisitors = TodayVisitors + 1 ' ¿À´Ã ¹æ¹®ÀÚ Áõ°¡

    Set ObjVisitor = Nothing

    TodayVisitorPath = Application("ServerPath") + "/Visitors/TodayVisitors.dat"

    Set ObjVisitor = FileObject.CreateTextFile (TodayVisitorPath, TRUE, FALSE)
    ObjVisitor.lock
    ObjVisitor.WriteLine(Today)
    ObjVisitor.WriteLine(TodayVisitors)
    ObjVisitor.unlock

    Application("TodayVisitors") = TodayVisitors

    Set ObjVisitor = Nothing
    ' ¿À´Ã ¹æ¹®ÀÚ Ä«¿îÆ® ³¡

    ' ¹æ¹®ÀÚ Á¤º¸ ±â·Ï ½ÃÀÛ
    ' ÀÌ ºÎºÐÀº ¹æ¹®ÀÚÀÇ Á¢¼ÓÁ¤º¸¸¦ ¾Ë¾Æ³»±â À§ÇÑ ºÎºÐÀÌ´Ù.
    ' ´©ÀûÄ«¿îÆ®¿Í ¿À´ÃÄ«¿îÆ®, ÇöÀçÄ«¿îÆ®, ³¯Â¥/½Ã°£, IP Address, SessionID, Á¢¼Ó¿¡ »ç¿ëÇÑ ºê¶ó¿ìÁ® °¡ ±â·ÏµÈ´Ù.
    Dim VisitorInfo()
    Redim VisitorInfo(1)

    i=0

    AppVisitorsPath = Application("ServerPath") + "/Visitors/"+Cstr(date())+".dat"

    Set ObjVisitor = FileObject.OpenTextFile (AppVisitorsPath)

    Do While Not ObjVisitor.AtEndOfStream
    CurLine = ObjVisitor.ReadLine
    VisitorInfo(i) = CurLine
    i = i + 1

    Redim Preserve VisitorInfo(i)

    Loop

    VisitorInfo(i) = Application("Visitors") & "---" & Application("TodayVisitors") & "---" & Application("NowVisitor") & "---" & now() & "---" & Request.ServerVariables("REMOTE_HOST") & "---" & Session.SessionID & "---" & Request.ServerVariables("HTTP_USER_AGENT") & chr(13)

    Set ObjVisitor= FileObject.CreateTextFile (AppVisitorsPath, TRUE, FALSE)

    ObjVisitor.lock

    for o=0 to i
    ObjVisitor.WriteLine(VisitorInfo(o))
    Next

    ObjVisitor.unlock

    Set ObjVisitor = Nothing

    ' ¹æ¹®ÀÚ Á¤º¸ ±â·Ï ³¡

    Set FileObject = Nothing

    Application.unlock

    'end if

    End Sub

    Sub Session_OnEnd

    'ÇöÀç ¹æ¹®ÀÚ¼ö °¨¼Ò ½ÃÀÛ
    Application.lock
    Application("NowVisitor")= Application("NowVisitor")-1

    if Application("NowVisitor") <= 0 then
    Application("NowVisitor")= 0
    end if

    Application.unlock
    'ÇöÀç ¹æ¹®ÀÚ¼ö °¨¼Ò ³¡

    Session.abandon
    End Sub

    Sub Application_OnStart
    Application.lock
    Application("NowVisitor") = 0 ' ÇöÀçÀÇ ¹æ¹®ÀÚ¼ö ÃʱâÈ­
    Application("ServerPath") = Server.MapPath ("/") ' À¥¼­¹öÀÇ ³í¸®°æ·Î ¼³Á¤
    Application.unlock
    End Sub
    </SCRIPT>

    ºÎŹµå·Á¿©^^

    Byte * 200 Byte À̳»·Î ÀÔ·ÂÇϼ¼¿ä À̸§ : Æнº¿öµå :