HEX
Server: Microsoft-IIS/10.0
System: Windows NT ITPWINWEBSVR22 10.0 build 20348 (Windows Server 2022) AMD64
User: www.conferencesearch.co.uk (0)
PHP: 8.3.30
Disabled: NONE
Upload Files
File: D:/web/castironradiatorcentre/2024-11-18/prev/inc-pages.asp
<%
' called for every request, calls the appropriate routine, page holds the page name, defaults to products'
' (SS,17/4/12) modified to allow pages directly from sitedetails table without needing separate templates for customer info, about, how to order, links etc.
' (SS,22/5/12) added reviews
' (SS,17/1/13) added hook to CustomShowPageContent for content from third party SEO company
' (SS,11/12/18) Added HTMLEncode to render of page name (FPageName) chosen to prevent XSS
' (SS,23/10/23) Added FPageName = "competition" DoCompetitionForm, new template file (inc-template-competition.asp)
' (SS,30/10/23) Added FPageName = "blog" DoBlogPage, new template file (inc-template-blog.asp)

Dim FPageName
FPageName = LCase(Request.QueryString("page"))
' (SS,1/7/11) added Request.QueryString("search") <> "" 
' (SS,7/10/15) added missing brackets after the "And"
If FPageName = "products" Or (FPageName = "" And (Request.QueryString("cmd") <> "" Or Request.QueryString("code") <> "" Or Request.QueryString("cat") <> "" Or Request.QueryString("search") <> "")) Then
  ShowPage_products
' (SS,20/6/11) added demolition
ElseIf FPageName = "demolitionservices" Then
  ShowPage_demolition
ElseIf FPageName = "contact" Then
  DoContactForm
' (SS,22/5/12)
ElseIf FPageName = "reviews" Then
  DoReviewsPage  
ElseIf FPageName = "account" Then
  DoAccount ' (SS,22/6/09) replaced DoCreateAccountForm, DoAccountLogout, DoAccountLogin and DoForgotPassword with just DoAccount  
ElseIf FPageName = "btucalculator" Then ' (SS,23/6/11)
  ShowPage_btucalculator
ElseIf FPageName = "radiatorbuilder" Then ' (SS,15/7/11)
  ShowPage_radiatorbuilder 
ElseIf FPageName = "competition" Then ' (SS,23/10/23)
  DoCompetitionForm
ElseIf FPageName = "blog" Then ' (SS,30/10/23)
  DoBlogPage
ElseIf FPageName = "" Or FPageName = "home" Then  
  ShowPage_home
ElseIf PageExists(FPageName) Then
  ShowPageContent(FPageName)
  ' if IIS has redirect to 404 error page (i.e. page=404) then set the status to 404
  If FPageName = "404" Then
    Response.Status = "404 Not Found" ' tells the browser that page was not found
  End If
' (SS,17/1/13) added CustomPage for integration with content from SEO company
ElseIf CustomPagesEnabled And CustomPageExists(FPageName) Then
  CustomShowPageContent(FPageName)
Else ' page doesn't exist so return 404 error, and display page does not exist message
  ' (SS,11/12/18) Added HTMLEncode to FPageName to prevent XSS
  Response.Write "<strong>Sorry, page '" & HTMLEncode(FPageName) & "' does not exist.</strong>"  
  Response.Status = "404 Not Found" ' tells the browser that page was not found
End If
%>