ASP,With,code,send,mail,thrugh,CDONTS,objecti
Quick Search for:  in language:    
ASP,With,code,send,mail,thrugh,CDONTS,objecti
   Code/Articles » |  Newest/Best » |  Community » |  Jobs » |  Other » |  Goto » | 
CategoriesSearch Newest CodeCoding ContestCode of the DayAsk A ProJobsUpload
ASP/ VbScript Stats

 Code: 132,008 lines
 Jobs: 198 postings

 
Sponsored by:

 

You are in:

 
Login


 

 


Latest Code Ticker for ASP/ VbScript.
if i remember, this is a M. Harris code sample
By ask on 8/24


MTS Registration Script
By Igor Krupitsky on 8/23


Click here to see a screenshot of this code!Creating Windows Users with ASP and ADSI
By James P. Walters on 8/23

(Screen Shot)

News Poster (Advanced)
By Martin Kilbryde on 8/22


Print a web document through MS Word
By ask on 8/22


Click here to see a screenshot of this code!ADSI Domain Group Explorer
By Gordon Asbach on 8/22

(Screen Shot)

_-~Who is looking at your site? v2.0!~-_
By John on 8/22


Using HTML Option to Display Current Month
By Patrick Ingle on 8/20


FdB: Free Database (Aka Fake Database)
By TV2k.net on 8/19


Click here to put this ticker on your site!


Add this ticker to your desktop!


Daily Code Email
To join the 'Code of the Day' Mailing List click here!





Affiliate Sites



 
 
   

Anonymous Mailer

Print
Email
 
VB icon
Submitted on: 5/16/2000 12:20:52 PM
By: Ido Diamant 
Level: Beginner
User Rating: By 9 Users
Compatibility:ASP (Active Server Pages)

Users have accessed this code 18855 times.
 

 
     With this code, you can send mail thrugh the web with ASP, with the CDONTS object. it is very simple script, I wrote it in 10 minutes and I am just a beginner (one month).
 
Can't Copy and Paste this?
Click here for a copy-and-paste friendly version of this code!

    '**************************************
    ' for :Anonymous Mailer
    '**************************************
    Ido Diamant © 2000
code:
Can't Copy and Paste this?
Click here for a copy-and-paste friendly version of this code!
 
Terms of Agreement:   
By using this code, you agree to the following terms...   
1) You may use this code in your own programs (and may compile it into a program and distribute it in compiled format for languages that allow it) freely and with no charge.   
2) You MAY NOT redistribute this code (for example to a web site) without written permission from the original author. Failure to do so is a violation of copyright laws.   
3) You may link to this code from another website, but ONLY if it is not wrapped in a frame. 
4) You will abide by any additional copyright restrictions which the author may have placed in the code or code's description.

    '**************************************
    ' Name: Anonymous Mailer
    ' Description:With this code, you can se
    '     nd mail thrugh the web with ASP, with th
    '     e CDONTS object.
    it is very simple script, I wrote it In 10 minutes and I am just a beginner (one month).
    ' By: Ido Diamant
    '
    ' Assumes:You just need to put this file
    '     in directory which you can run scripts f
    '     rom it, and you should install the SMTP 
    '     add-on in the Option Pack 4.
    '
    'This code is copyrighted and has    ' limited warranties.Please see http://w
    '     ww.Planet-Source-Code.com/xq/ASP/txtCode
    '     Id.6158/lngWId.4/qx/vb/scripts/ShowCode.
    '     htm    'for details.    '**************************************
    
    <% if request.form("flag")=""then %>
    <HTML>
    <H1>Welcome To Anonymous Mailer by Ido Diamant</H1>
    <H4>** Please enter all the required fields or it won't be send...</H4>
    <FORM action=anonymous.asp method=post>
    <TABLE border=0 cellPadding=1 cellSpacing=1 style="HEIGHT: 184px; WIDTH: 457px" 
    width="75%">
    <TR>
    <TD>From: </TD>
    <TD><INPUT name=From size=30 style="HEIGHT: 22px; WIDTH: 321px"></TD></TR>
    <TR>
    <TD>To: </TD>
    <TD><INPUT name=To size=30 style="HEIGHT: 22px; WIDTH: 321px"></TD></TR>
    <TR>
    <TD>Subject: </TD>
    <TD><INPUT name=Subject size=50 style="HEIGHT: 22px; WIDTH: 321px"></TD></TR>
    <TR>
    <TD>Body of Message: <BR></TD>
    <TD><TEXTAREA cols=30 name=Body rows=5 style="HEIGHT: 86px; WIDTH: 322px" wrap=virtual>Message Body</TEXTAREA></TD></TR></TABLE>  <BR>  <BR> <BR><BR>
    <INPUT type="submit" value="Send Mail">
    <INPUT type="hidden" name="flag" value="1">
    </HTML>
    <%
    Else
    Dim anonFrom,anonTo,anonSubj,anonBody
    anonFrom = request.form("From")
    anonTo = request.form("To")
    anonSubj = request.form("Subject")
    anonBody = request.form("Body")
    Set objMail = CreateObject("CDONTS.NewMail")
    objMail.From=anonFrom
    objMail.To=anonTo
    objMail.Subject=anonSubj
    objMail.Body=anonBody
    intReturn=objMail.Send()
    %>
    <HTML>
    <H1>The message sent successfully</H1>
    <INPUT type='button' value='Back' onclick=history.back()>
    </HTML>
    <%
    End if
    %>

 
Report Bad Submission
Use this form to notify us if this entry should be deleted (i.e contains no code, is a virus, etc.).
Reason:
 
Your Vote!

What do you think of this code(in the Beginner category)?
(The code with your highest vote will win this month's coding contest!)
Excellent  Good  Average  Below Average  Poor See Voting Log
 
Other User Comments
5/29/2000 6:12:39 PM:Ian Ippolito
A hint to users: don't forget to name 
this form anonymous.asp to make this 
work!
Ian
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
6/2/2000 10:59:26 PM:Wayne Snyder
If you have IIS 4.0, you don't need to 
declare variables of type Dim; just 
skip straight to initialization of the 
variables.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
6/2/2000 11:02:02 PM:Wayne Snyder
After your <% End If %> statement, you 
can put the code for another html page 
that, for example, may tell the user 
that the email was sent, when it was 
sent, and then redirect them back to 
the email page.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
6/2/2000 11:03:20 PM:Wayne Snyder
You can continue to add more variables 
and text from the form to the strBody 
variable (or whatever you want to name 
it) so that you can even send the 
entire contents of a page (for example, 
a form the user has filled out) to one, 
or several, recipients.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/19/2000 4:50:45 PM:Reddy
How can I avoid this ActiveX component 
can't create object: 'CDONTS.NewMail' 
My mailID reddyt@comsquared.com
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/19/2000 4:52:07 PM:Reddy
How can I avoid this error:
ActiveX 
component can't create object: 
'CDONTS.NewMail' 
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
10/28/2000 7:52:41 PM:David
Thanks Ido and others.  It works!  
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
11/13/2000 8:02:09 PM:Michael
I'm having the same problem as that 
other guy:
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
11/14/2000 3:09:38 PM:Ido Diamant
If you can try to tell me what exactly 
is the problem with this activex 
component I could maybe help you...
if 
you want, contact me by email, it is 
much 
comfortable!
idodi@surfree.net.il
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
11/14/2000 3:11:34 PM:Ido Diamant
Just for your knowledge, in few days my 
new site http://www.aspdeveloping.com 
will be openning!
you are all invited 
to come and help me developing it and 
making it good...
thanks!
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
12/2/2000 11:55:35 AM:dappa
i cannot use the asp script , i get a 
message http error 405 , resource not 
allowed.
Can anyone help please??
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
12/24/2000 4:50:04 AM:Asaf
i have aproblem with the 
cdonts.dll
Microsoft VBScript runtime 
(0x800A01AD)
ActiveX component can't 
create object: 'CDONTS.NewMail'
i have 
w2k server - and exchange 5.5 on the 
same server thanx
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
2/22/2001 1:43:40 PM:john untener
Can you tell me why I get the following 
error:
Active Server Pages error 
'ASP 0224' 
Cannot load TypeLib 
/onlineservice/orderforms/titlesearchc
onfirmation.asp, line 1 
Cannot load 
Type Library specified in the METADATA 
tag. 
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
2/23/2001 4:25:00 PM:Jeff
I am getting the same Microsoft 
VBScript runtime 
(0x800A01AD)
ActiveX component can't 
create object: 'CDONTS.NewMail'
I 
think it is because the SMTP Service 
from the NT4 option pack is not 
installed.  You cannot have both the 
Exchange Internet Mail Service and the 
SMTP Service from the Option Pack on 
the same machine.  I'm currently 
figuring out how to use Exchange for my 
automatic email replies.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
7/5/2001 7:43:47 PM:Randy Chow
On Windows 2000 Server I can't get this 
code to work.  I heard it should.  I 
only have IIS5.0 installed as default, 
should there be extra settings for SMTP 
before I can use this?  Help please, 
really need it quick to work.  Thanks
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
7/19/2001 2:37:22 AM:Web-Exodus.com
The way this code it written, it has no 
chance whatsoever of working. It doesnt 
even use SMTP!!...This is shockingly bad
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
8/16/2001 1:17:06 PM:Chris
Web-Exodus - I almost feel sorry for 
you. Almost.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
11/8/2001 5:12:45 AM:Kobus
It is also nice to have the following: 
objMail.Importance = 1 (Can get this 
from the form as well)
Then the last 
bit like this: objMail.BodyFormat = 
0
objMail.MailFormat = 0
objMail.Body 
= BodyText
objMail.Send
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
11/26/2001 8:27:09 AM:First Knight
You all have to keep in mind that the 
activeX Componont has to be installed 
on the server, and that you have to 
have the permission to use it. If you 
host you site with some free server, 
You probably won't be able to use 
it.
Because if you make a loop of it, 
you can mailbomb someone.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
1/31/2002 11:00:41 AM:Don
This is the very epitamy of the KISS 
principle.  You are a Natural 
Programmer!  Very Nicely Done.
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
3/14/2002 9:29:39 PM:Jos Keuter
Dudes! This code, allthough it's nice 
work from a rooky, is not as anonymous 
as you might think! Of course the 
sender is fake but send a fake message 
to yourself and see the header 
information. Yeps, the server address 
is visible! So anyone can track down 
your server... that's not what we want 
isn't it? So be sure the server you're 
working with is anonymous!!!
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
5/15/2002 12:56:00 AM:Red Dick
your code is nice..but it is useless
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
5/24/2002 7:55:07 AM:koko
Terrific !
Keep the Planet clean! If this comment was disrespectful, please report it:
Reason:

 
Add Your Feedback!
Note:Not only will your feedback be posted, but an email will be sent to the code's author in your name.

NOTICE: The author of this code has been kind enough to share it with you.  If you have a criticism, please state it politely or it will be deleted.

For feedback not related to this particular code, please click here.
 
Name:
Comment:

 

Categories | Articles and Tutorials | Advanced Search | Recommended Reading | Upload | Newest Code | Code of the Month | Code of the Day | All Time Hall of Fame | Coding Contest | Search for a job | Post a Job | Ask a Pro Discussion Forum | Live Chat | Feedback | Customize | ASP/ VbScript Home | Site Home | Other Sites | About the Site | Feedback | Link to the Site | Awards | Advertising | Privacy

Copyright© 1997 by Exhedra Solutions, Inc. All Rights Reserved.  By using this site you agree to its Terms and Conditions.  Planet Source Code (tm) and the phrase "Dream It. Code It" (tm) are trademarks of Exhedra Solutions, Inc.