<%@LANGUAGE="VBSCRIPT"%> <% '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' ' Spd E-Letter v4 ' © 2001, 2002 PensaWorks, inc. ' For help with this program, please visit http://www.pensaworks.com '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' Dim Access : Access = "User" Dim Nav3 : Nav3 = "2" %> <% subID = 0 if (request("ID") <> "") then subID = request("ID") if (NOT IsNumeric(subID)) then subID = 0 if (subID = 0) then response.redirect "message.asp?msg=20" set getSubDetails = mlConn.Execute("SELECT ML_Lists.ListID AS ListID1, * FROM ML_Subscribers INNER JOIN ML_Lists ON ML_Subscribers.ListID = ML_Lists.ListID WHERE ML_Subscribers.SubscriberID = " & subID) if (getSubDetails.EOF) then response.redirect "message.asp?msg=20" ListID = getSubDetails("ListID1") if not allowedList(listID, allowedLists) then response.redirect "message.asp?msg=49" showReads = "off" showClicks = "off" if (request("r") = "on") then showReads = "on" if (request("c") = "on") then showClicks = "on" %> <%=ListName%> - Spd E-Letter Administration

Subscriber Stats

<% set receivedNewsletters = mlConn.Execute("SELECT COUNT(*) AS Count1 FROM ML_Broadcast WHERE Status = 'Broadcasted' AND ListID = " & ListID & " AND MessageType = 'R' AND msgBroadcastedDate >= " & getSubDetails("SubscribedDate")) %> <% set lastNewsletter = mlConn.Execute("SELECT * FROM ML_Broadcast WHERE MessageType = 'R' AND ListID = " & ListID & " ORDER BY msgBroadcastedDate DESC") %> <% set lastClick = mlConn.Execute("SELECT * FROM ML_Clicks INNER JOIN ML_URLs ON ML_Clicks.clkURLID = ML_URLs.urlID WHERE ML_Clicks.clkSubscriberID = " & subID & " ORDER BY clkLastDate DESC") %> <% set lastRead = mlConn.Execute("SELECT * FROM ML_Reads WHERE readSubscriberID = " & subID & " ORDER BY readLastDate DESC") %>
Subscriber Details
Name:
<%=getSubDetails("Name")%>
Email Address:
<%=getSubDetails("Email")%>
Subscribed List:
<%=getSubDetails("Listname")%>
Format:
<% Format = whichFormat(getSubDetails("Format")) : response.write Format %>
Subscribe Date:
<%=getDateFromNum(getSubDetails("SubscribedDate"))%>
Unsubscribed?
<% if getSubDetails("subRemoved") = 1 then %> Yes <% else %> No <% end if %>
Unsubscribe Date:
<% if getSubDetails("subRemoved") = 1 then %> <%=getDateFromNum(getSubDetails("subRemovedDate"))%> <% else %> Not unsubscribed <% end if %>
Total Newsletter Bounces:
<%=getSubDetails("numBounces")%>
Total Email Replies:
<%=getSubDetails("numReplies")%>
Total URL Clicks:
<% numClicks = getSubDetails("numClicks") : response.write numClicks %> -  <% if (showClicks = "on") then %> Hide Details <% else %> Show Details <% end if %>
Total Newsletter Reads:
<% numReads = getSubDetails("numReads") : response.write numReads %> -  <% if (showReads = "on") then %> Hide Details <% else %> Show Details <% end if %>

Received Newsletters:
<%=receivedNewsletters("Count1")%> total Newsletters received
Last Newsletter Received:
<% if lastNewsletter.EOF then %> None received yet. <% else %> "><%=lastNewsletter("Subject")%> <% end if %>
Last Click:
<% if lastClick.EOF then %> n/a <% else %> <%=getDateFromNum(lastClick("clkLastDate"))%> - ">Preview Newsletter | ">Newsletter Report <% end if %>
Last Read:
<% if lastRead.EOF Then %> n/a <% else %> <%=getDateFromNum(lastread("readLastDate"))%> - ">Preview Newsletter | ">Newsletter Report <% end if %>
Advanced Newsletter Read Tracking is currently <% if prefReads = 1 then %> on <% else %> off <% end if %> .
Advanced Click Tracking is currently <% if prefClicks = 1 then %> on <% else %> off <% end if %> .


<% if showClicks = "on" then set getClicks = mlConn.Execute("SELECT ML_Broadcast.MessageID AS mesID, * FROM ML_Clicks INNER JOIN (ML_URLs INNER JOIN ML_Broadcast ON ML_URLs.MessageID = ML_Broadcast.MessageID) ON ML_URLs.urlID = ML_Clicks.clkURLID WHERE ML_Clicks.clkSubscriberID = " & subID & " ORDER BY ML_Clicks.clkLastDate DESC") %> <% if getClicks.EOF then %> <% else %> <% num = 0 while (NOT getClicks.EOF) num = num + 1 %> <% getClicks.MoveNext() response.flush() wend %> <% end if %>
<%=numClicks%> Total URL Clicks (Hide Details)

No URL Click Details Found
# Newsletter URL Clicks Last Click
<%=num%> "><%=getClicks("Subject")%> " target="_blank"><%=getClicks("urlRedirect")%>
<%=getClicks("clkNumTimes")%>
<%=getDateFromNum(getClicks("clkLastDate"))%>


<% end if %> <% if showReads = "on" then set getReads = mlConn.Execute("SELECT * FROM ML_Reads INNER JOIN ML_Broadcast ON ML_Reads.readMessageID = ML_Broadcast.MessageID WHERE ML_Reads.readSubscriberID = " & subID & " ORDER BY readLastDate DESC") %> <% if getReads.EOF then %> <% else %> <% num = 0 while (NOT getReads.EOF) num = num + 1 %> <% getReads.MoveNext() response.flush() wend end if %>
<%=numReads%> Total Newsletter Reads (Hide Details)

No Newsletter Read Details Found
# Newsletter Reads Last Read
<%=num%> "><%=getReads("Subject")%>
<%=getReads("readNumTimes")%>
<%=getDateFromNum(getReads("readLastDate"))%>


<% end if %>