WebPublisher

[asp] 호출한(이전) 페이지 이름(url) 알아내기

amanda 2023. 10. 13. 15:05

include 된 asp 파일에서 이전에 호출한 페이지 url 알아내기

<%
    Dim referUrl, cate, crtCate

    referUrl = Request.ServerVariables("HTTP_REFERER")
    cate = split(LCase(referUrl), "/")
    crtCate = cate(5)

    If crtCate = "test.asp" Then
%>
    <script>
    	// script 내용
    </script>
<% 
    End If
%>