<% Dim objRS, sig, bodyquote, messageID, threadID dim rights,allforum, emnotify, PGDCode, forumID Dim r_do, appid, arrReply, emailview, allowupload, isPostAllowed Dim oriMsgIcon, alwaysSig, upRestriction,isUploadAllowed,strSQL,temparr,NoIMGinPosts Dim parentAuthor dim sendto, allowmail:allowmail = Application(dbName&"maildll") Dim requireEmailView if isAdmin then requireEmailView = "" else requireEmailView = " And emailview=1" isPostAllowed = true if isGuest or allowmail="NoMail" then isPostAllowed = false end if if request.form <>"" and isPostAllowed then if request.form("jsenabled")="false" then response.redirect (forumdir&"first.asp") response.end end if if not fromThisDomain("email.asp?") then response.redirect (forumdir&"first.asp?error=referer") response.end end if dim senderE,senderN,mailTo,mailCC,mailBCC,subject,body sendto = request.form("sendto") senderN = memLogin & " from " & Application(dbName&"ForumTitle") mailBCC = "" subject = request.form("subject") body = request.form("body") set objRS = Server.createobject("ADODB.RECORDSET") strSQL = "SELECT email from pgd_members where mem in ("&CheckDelimitedFormat(SQLstrip(sendto),",")&")"&requireEmailView objRS.open strSQL, datastore, , , adCmdText if not (objRS.EOF or objRS.BOF) then mailTo = objRS.getString(,,"",";","") 'mailTo = objRS(0) end if objRS.close objRS.open "SELECT email from pgd_members WHERE mem="&Clng(memID) senderE = objRS(0) objRS.close Set objRS = nothing if request.form("mailCC")= "on" then mailCC = senderE else mailCC = "" end if '=========================================================================== call mailRoutine(senderE,senderN,mailTo,mailCC,mailBCC,subject,body) '=========================================================================== response.write(""& emailSuccessfulDesc &"") response.end end if if isPostAllowed then 'Checking Upload Permission sendto = request.querystring("memid") Dim arrmems if len(sendto) = 0 then isPostAllowed = false ' response.write "SELECT mem,login from pgd_members where mem in ("&CheckDelimitedFormat(SQLstrip(sendto),",")&") AND emailview=1" if isPostAllowed then set objRS = Server.createobject("ADODB.RECORDSET") strSQL = "SELECT mem,login from pgd_members where mem in ("&CheckDelimitedFormat(SQLstrip(sendto),",")&")"&requireEmailView objRS.open strSQL, datastore, , , adCmdText if not (objRs.EOF or objRS.BOF) then arrmems = objRS.getRows end if objRS.close Set objRS = nothing if not isArray(arrmems) then isPostAllowed = false ' response.write isPostAllowed end if end if if isPostAllowed then mailto = arrmems(1,0) sendto = CheckDelimitedFormat(Join(ExtractOneDimension(arrmems,0),","),",") end if %> <%= Application(dbName&"forumtitle") %> <%= NoScript() %> <%= OutputCSS() %> <% Dim onload if isPostAllowed then onload = "onload=""document.forms[0].subject.focus();""" end if %> <%= tablealt %> <%= Application(dbName&"bodyoption") %> style="margin:0px 0px 0px 0px">
<% if isPostAllowed then %> <% else %> <% end if %>
<%= iff(request.querystring("do")="report",tmReportDesc,tmemail&mailto) %>
rowspan="2" valign="top" class="c2"><%= tmName %> > <%=( memLogin ) %>
> <%= emailCopyToSelfDesc %>
class="c2" valign="top"> <%= tmSubject %> > ">
class="c2">

<%= bodyFieldDesc %>

> <%=pgdBodyArea(HTMLEncode(""&request.querystring("body")),14)%>
colspan="2" align="center" class="subhead"><%= RightViolationMessage %>

<% if isPostAllowed then %> <% end if %>

<% call pgdResize(200,"body") %>