This repository has been archived by the owner on Nov 10, 2017. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathdefault.asp
93 lines (80 loc) · 3.03 KB
/
default.asp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
<%@Language="VBScript"%>
<%
Option Explicit
'(C) Copyright MMIX Matthew Juffs (Slickhouse.com) - released under the Microsoft Reciprocal License (Ms-RL)
%>
<!--#include virtual="/slickcms/slickcms.asp"-->
<%
'open global connection to database
Call OpenDatabase()
Set objSlickCMS = New SlickCMS
Set objPost = New Post
Set objCaptcha = New Captcha
Set objComment = New Comment
Set objCategory = New Category
Set objTag = New Tag
Set objStatistic = New Statistic
'determines which page we're on and sets the various variables used from here on
Call UrlHandler()
'search
objPost.Keywords = Request.Form("keywords")
objPost.SearchTemplate = "<p><a href=""[url]"">[title]</a> - [summary]</p>"
'contact form post
If objPost.Url = "send-message" Then
If objCaptcha.Process <> "pass" Then
Session("EmailSent") = false
Else
Call objSlickCMS.SendMessage(Request.Form("email"), Request.Form("message"), Request.Form("name"))
End If
'set Session so user can re-use their entered data
Session("Name") = Request.Form("name")
Session("Email") = Request.Form("email")
Session("Comment") = Request.Form("message")
Response.Redirect("/contact/")
Response.End
End If
'retrieve post if single page
Select Case objPost.UrlType
Case "post","date" 'single item
Call objPost.GetPost()
End Select
'generate meta tag data
Call objSlickCMS.Meta()
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title><%=strTitle%></title>
<meta name="language" content="en-UK" />
<meta name="description" content="<%=strDescription%>" />
<meta name="generator" content="SlickCMS <%=Application("SlickCMS_Version")%>" />
<meta name="verify-v1" content="<%=Application("GoogleVerifyTag")%>" />
<link href="<%=Application("CDN")%>css/screen.css" rel="stylesheet" type="text/css" media="screen" />
<%Call objSlickCMS.CSS()%>
<link rel="alternate" type="application/rss+xml" title="<%=Application("SiteName") & " Posts RSS 2.0 Feed"%>" href="<%=Application("SiteURL")%>rss2.asp?t=posts" />
<link rel="alternate" type="application/rss+xml" title="<%=Application("SiteName") & " Comments RSS 2.0 Feed"%>" href="<%=Application("SiteURL")%>rss2.asp?t=comments" />
</head>
<body>
<div id="page">
<!--#include virtual="/header.asp"-->
<!--#include virtual="/sidebar.asp"-->
<!--#include virtual="/content.asp"-->
<!--#include virtual="/footer.asp"-->
</div>
<script src="<%=Application("CDN")%>scripts/slickcms.js" type="text/javascript"></script>
<%=objSlickCMS.GoogleAnalytics()%>
</body>
</html>
<%
'destroy objects
Set objStatistic = Nothing
Set objTag = Nothing
Set objCategory = Nothing
Set objComment = Nothing
Set objCaptcha = Nothing
Set objPost = Nothing
Set objSlickCMS = Nothing
'close global connection to database
Call CloseDatabase()
%>