Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Community Forums
 Code Support: ASP (Non-Forum Related)
 Contact Form Page email
 New Topic  Topic Locked
 Printer Friendly
Previous Page
Author Previous Topic Topic Next Topic
Page: of 2

Shaggy
Support Moderator

Ireland
6780 Posts

Posted - 20 February 2007 :  10:16:08  Show Profile
You're welcome, Jeff


Search is your friend
“I was having a mildly paranoid day, mostly due to the
fact that the mad priest lady from over the river had
taken to nailing weasels to my front door again.”
Go to Top of Page

JJenson
Advanced Member

USA
2121 Posts

Posted - 12 March 2007 :  10:50:24  Show Profile  Visit JJenson's Homepage
Sorry to bring this back up I just noticed I am having issues with my script I thought a while back I had it working but apparently not.

Ok so basically I have added in the code Shaggy has told me and I think I need to take out some of the other code I have but I am not sure?

The problem is I am not getting emails to me at all right now. I am not sure where I broke this to not send at all?

Any suggestions on making the script work from here would be greatly appreciated.


<%
   if UCase(Request.Form("submit")) = "SUBMIT" then
      SendFormResults "support@thebragboard.com"
   end if

Sub SendFormResults(sendTo)
   Dim results
   results = "Question Form Results:" & vbcrlf & vbcrlf
   
   results=results&"First Name: "&request.form("fname")&vbnewline
   results=results&"Organization Name: "&request.form("oname")&vbnewline
   results=results&"Comments: "&request.form("comments")&vbnewline
   results=results&"Telephone Number: "&request.form("telephone_number")&vbnewline
   results=results&"Best Time To Contact: "&request.form("besttime")&vbnewline
   results=results&"Time Zone: "&request.form("zone")&vbnewline
   results=results&"Email: "&request.form("email")&vbnewline
   results=results&"City: "&request.form("city")&vbnewline
   results=results&"State: "&request.form("state")&vbnewline
  	  
   Dim iMsg
   Dim iConf
   Dim Flds
   Dim strHTML

   Const cdoSendUsingPickup = 1

   set iMsg = CreateObject("CDO.Message")
   set iConf = CreateObject("CDO.Configuration")

   ' set the CDOSYS configuration fields to use the SMTP service pickup directory
   Set Flds = iConf.Fields
   With Flds
      .Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = cdoSendUsingPickup
      .Item("http://schemas.microsoft.com/cdo/configuration/smtpserverpickupdirectory") = "c:\inetpub\mailroot\pickup"
      .Update
   End With

   Set iMsg.Configuration = iConf
   iMsg.To = sendTo
   iMsg.From = sendTo
   iMsg.Subject = "Questions for The Brag Board"
   iMsg.TextBody = results
   iMsg.Send
   
   set iMsg = nothing
   set iConf = nothing
   
End Sub
%>


Edited by - JJenson on 12 March 2007 10:52:21
Go to Top of Page

JJenson
Advanced Member

USA
2121 Posts

Posted - 13 March 2007 :  09:06:15  Show Profile  Visit JJenson's Homepage
OK upon further review I don't think it is the form that is the problem anymore. Back when I did this like 3 weeks ago or whatever it would send emails now it is not sending them at all and I cannot seem to find the answer any help would be greatly appreciated?

This seems dumb to me I can do mods and a bunch of modifying on the forum and I can't write a simple emial script grrrr so annoying.
Go to Top of Page

JJenson
Advanced Member

USA
2121 Posts

Posted - 15 March 2007 :  11:58:30  Show Profile  Visit JJenson's Homepage
Just to put an end on this. I got some info from my host and now I completely re did the page and its actually much simpler now in my opinion than before and works perfectly. Thanks shaggy for the help as well as others. Also feels good to finianlly have this resolved.

Oh by the way the old code worked until my host did some upgrades then I had to switch to using CDOSYS and changed a few fields and took shaggys advice to write it out for each field I want to get. Works wonderfully.

Thanks All
Go to Top of Page

Shaggy
Support Moderator

Ireland
6780 Posts

Posted - 15 March 2007 :  12:07:08  Show Profile
Was about to say that if it was working before and now it's not without you having made any changes then something's obviously changed on the server. You've spotted that already, though Glad to be of whatever service I was


Search is your friend
“I was having a mildly paranoid day, mostly due to the
fact that the mad priest lady from over the river had
taken to nailing weasels to my front door again.”
Go to Top of Page

JJenson
Advanced Member

USA
2121 Posts

Posted - 15 March 2007 :  12:09:28  Show Profile  Visit JJenson's Homepage
Yeah the results code you gave me I just had to modify it just a bit and put it in a different way and work like a charm. I know that was for the other code so of course editing was neccasary but glad for the tip I think I understand how contact forms work.

1 thing down about 4 million to go

At this rate it will only take me till I am 12 million years old to learn it all
Go to Top of Page
Page: of 2 Previous Topic Topic Next Topic  
Previous Page
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.27 seconds. Powered By: Snitz Forums 2000 Version 3.4.07