Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Basic
  4. Blank Mail ASP

Blank Mail ASP

Scheduled Pinned Locked Moved Visual Basic
helpquestionjavascripthtmlcom
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • F Offline
    F Offline
    for1206
    wrote on last edited by
    #1

    Hi CodeProject , I wrote a javascript to validate the fields on the contact form . But it is working in my system. After deploying in Main server . I am getting BLANK fields values . What is the problem ? This the code

    <%@language = "VBscript"%>

    <%

    set objMessage = createobject("cdo.message")
    set objConfig = createobject("cdo.configuration")

    ' Setting the SMTP Server
    Set Flds = objConfig.Fields
    Flds.Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = 1
    Flds.Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = "xyz"
    Flds.Item("http://schemas.microsoft.com/cdo/configuration/smtpserverport")=25
    Flds.update

    dim b
    b= "Name : " & Request.Form("Name") & vbCrLf
    b= b & "Organisation : " & Request.Form("Organisation")& vbCrLf
    b= b & "Title : " & Request.Form("Title")& vbCrLf
    b= b & "Address : " & Request.Form("Address")& vbCrLf
    b= b & "City : " & Request.Form("City")& vbCrLf
    b= b & "Country : " & Request.Form("Country")& vbCrLf
    b= b & "Email : " & Request.Form("Email")& vbCrLf
    b= b & "Phone : " & Request.Form("Phone")& vbCrLf
    b= b & "Interesed in : " & Request.Form("category")& vbCrLf
    b= b & "Description : " & Request.Form("Description")& vbCrLf

    Set objMessage.Configuration = objConfig
    objMessage.To ="xyz@gmail.com"
    'objMessage.CC ="xyz@xyz.in"
    objMessage.From = "info@xyz.in"
    objMessage.Subject = "Contact Form - " & Request.Form("Organisation") & vbCrLf
    objMessage.TextBody = "High priority - See details below. " & vbCrLf & vbCrLf & b

    on error resume next
    objMessage.Send
    if Err.Number <> 0 then
    response.Write "Email sending failed: " & Err.Description & ".<br />"&vbcrlf
    else
    response.redirect("contact_submit.html")
    end If
    Response.End
    set objMessage = nothing
    set objConfig = nothing
    %>

    Regards,

    For1206

    T 1 Reply Last reply
    0
    • F for1206

      Hi CodeProject , I wrote a javascript to validate the fields on the contact form . But it is working in my system. After deploying in Main server . I am getting BLANK fields values . What is the problem ? This the code

      <%@language = "VBscript"%>

      <%

      set objMessage = createobject("cdo.message")
      set objConfig = createobject("cdo.configuration")

      ' Setting the SMTP Server
      Set Flds = objConfig.Fields
      Flds.Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = 1
      Flds.Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = "xyz"
      Flds.Item("http://schemas.microsoft.com/cdo/configuration/smtpserverport")=25
      Flds.update

      dim b
      b= "Name : " & Request.Form("Name") & vbCrLf
      b= b & "Organisation : " & Request.Form("Organisation")& vbCrLf
      b= b & "Title : " & Request.Form("Title")& vbCrLf
      b= b & "Address : " & Request.Form("Address")& vbCrLf
      b= b & "City : " & Request.Form("City")& vbCrLf
      b= b & "Country : " & Request.Form("Country")& vbCrLf
      b= b & "Email : " & Request.Form("Email")& vbCrLf
      b= b & "Phone : " & Request.Form("Phone")& vbCrLf
      b= b & "Interesed in : " & Request.Form("category")& vbCrLf
      b= b & "Description : " & Request.Form("Description")& vbCrLf

      Set objMessage.Configuration = objConfig
      objMessage.To ="xyz@gmail.com"
      'objMessage.CC ="xyz@xyz.in"
      objMessage.From = "info@xyz.in"
      objMessage.Subject = "Contact Form - " & Request.Form("Organisation") & vbCrLf
      objMessage.TextBody = "High priority - See details below. " & vbCrLf & vbCrLf & b

      on error resume next
      objMessage.Send
      if Err.Number <> 0 then
      response.Write "Email sending failed: " & Err.Description & ".<br />"&vbcrlf
      else
      response.redirect("contact_submit.html")
      end If
      Response.End
      set objMessage = nothing
      set objConfig = nothing
      %>

      Regards,

      For1206

      T Offline
      T Offline
      TheComputerMan
      wrote on last edited by
      #2

      Looks like VBScript to me not Javascript. Perhaps you might get an answer in the Web forum?

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups