%@LANGUAGE="VBSCRIPT" codepage=1252%>
<% ' Displaying News 'Session.LCID = 1025 Session.CodePage = 1252 Dim cnnLogin Dim rs, rs1 Dim strUsername, strPassword Dim strSQL, strSQL1, data_source, RowCount data_source = "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" & _ Server.MapPath("All.mdb") Set cnnLogin = Server.CreateObject("ADODB.Connection") cnnLogin.Open "DSN=sstdtorgsa_ALL;UID=sstdt;PWD=dtsst" Set rs = Server.createobject("ADODB.Recordset") Set rs1 = Server.createobject("ADODB.Recordset") strSQL = "SELECT * FROM news ORDER BY (id) desc" strSQL1 = "SELECT * FROM advertisement ORDER BY (id) desc" 'Set rstLogin = cnnLogin.Execute(strSQL) rs.Open strSQL, cnnLogin rs1.Open strSQL1, cnnLogin ' Closing News %> <% ' Mailing Code Dim name, company, city, country, tel, fax, companies, mobile, email, comments, strBody name = (Request.Form("name")) mobile = (Request.Form("mobile")) email = (Request.Form("email")) remarks = (Request.form("remarks")) strBody = "تجئي رسالة من الموقع الجمعية السعودية لتطوير ونقل التقنية" & vbcrlf & vbcrlf strBody = strBody & "الاسم:" & name & vbcrlf strBody = strBody & "جوال:" & mobile & vbcrlf strBody = strBody & "بريد الإلكتوني:" & email & vbcrlf strBody = strBody & "التعليق:" & vbcrlf strBody = strBody & remarks strHost = "mail.sstdt.org.sa" If Request("Comments") <> "" Then Set Mail = Server.CreateObject("Persits.MailSender") ' enter valid SMTP host Mail.Host = strHost Mail.From = email ' From address Mail.FromName = Mail.EncodeHeader(Request.Form("name"), "windows-1256") ' optional Mail.EncodeHeader( "windows-1256" ,) Mail.AddAddress "info@sstdt.org.sa" Mail.Charset = "Windows-1256" Mail.ContentTransferEncoding = "Quoted-Printable" ' message subject Mail.Subject = Mail.EncodeHeader("تجئي رسالة من الموقع الجمعية السعودية لتطوير ونقل التقنية", "windows-1256") 'Mail.EncodeHeader( , "windows-1256") ' message body Mail.Body = strBody strErr = "" bSuccess = False On Error Resume Next ' catch errors Mail.Send ' send message If Err <> 0 Then ' error occurred strErr = Err.Description else bSuccess = True End If End If %>
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||