글 읽을때 조회수 증가 체크(쿠키 이용)
본문
'-------------------------------------------------
' 쿠키 중복 체크
'-------------------------------------------------
Function CookieDuplicateCheck(tableName, idx)
dim dupliChk
dim c_read_idx
dim i
dupliChk = false
c_read_idx = Request.Cookies("C_TABLE_NAME")("READ")
Response.Cookies("C_TABLE_NAME") = tableName
Response.Cookies("C_TABLE_NAME").Path = "/"
Response.Cookies("C_TABLE_NAME").Expires = date+1
arrRead = split(c_read_idx,",")
for i = 1 to UBound(arrRead)
if CInt(idx) = CInt(Trim(arrRead(i))) then
dupliChk = true
end if
next
if dupliChk = true then
Response.Cookies("C_TABLE_NAME")("READ") = c_read_idx
else
Response.Cookies("C_TABLE_NAME")("READ") = c_read_idx & "," & idx
end if
CookieDuplicateCheck = dupliChk
End Function
' 쿠키 중복 체크
'-------------------------------------------------
Function CookieDuplicateCheck(tableName, idx)
dim dupliChk
dim c_read_idx
dim i
dupliChk = false
c_read_idx = Request.Cookies("C_TABLE_NAME")("READ")
Response.Cookies("C_TABLE_NAME") = tableName
Response.Cookies("C_TABLE_NAME").Path = "/"
Response.Cookies("C_TABLE_NAME").Expires = date+1
arrRead = split(c_read_idx,",")
for i = 1 to UBound(arrRead)
if CInt(idx) = CInt(Trim(arrRead(i))) then
dupliChk = true
end if
next
if dupliChk = true then
Response.Cookies("C_TABLE_NAME")("READ") = c_read_idx
else
Response.Cookies("C_TABLE_NAME")("READ") = c_read_idx & "," & idx
end if
CookieDuplicateCheck = dupliChk
End Function
[이 게시물은 듀라님에 의해 2015-04-03 10:08:13 워드프레스에서 이동 됨]
[이 게시물은 듀라님에 의해 2015-04-03 10:27:24 Public에서 이동 됨]
[이 게시물은 듀라님에 의해 2015-04-03 10:33:53 팁과강좌에서 이동 됨]
[이 게시물은 최고관리자님에 의해 2017-06-10 14:24:30 ASP에서 이동 됨]
0
0
페이지 정보
l2j (121.♡.101.20) 작성일07-05-02 14:48 조회1,650회 댓글0건관련링크
댓글목록
등록된 댓글이 없습니다.