In fact, the ASP can do a lot, but everyone doesn't know how to use it. Microsoft provides a lot of ready-to-use components for ASP, but these components are known, if they send mail with cdo.message. What is cdo.message? Sending an email in WinNT and Win2k Use cdonts.newmail, cdonts.newmail components are registered, very simple, just run the command line regr32 cdonts.dll on the server, OK in the pop-up dialog box, use CDONTS. Newmail services also need to have IIS comes with SMTP. When I went to Windows2003, the system did not come with the cdonts.dll file, only one similar file cdosys.dll, of course this file is also there (need registration components), but what is it? The component has no need to manually register, and the system has been automatically registered. Let's take a look at how to use this component. <% DIM CMSET CM = Server.createObject ("cdo.Message") 'Create an object cm.from = "from@test.com" Set the sender's mailbox cm.to = "to@test.com" "Setting Letter's mailbox cm.subject = "I found a website that can subscribe to RSS online, I don't have to install what software will be installed." 'Setting the theme of the message' cm.textbody = "http://www.gbmad.net/RSS / "'The above is to send emails using ordinary text format, can only be text, can not support HTML, so here do not need cm.htmlbody =" Online RSS feeds Reader is an online RSS news reading system. "& _" No need to download and install, As long as you are registered, you can have a system of RSS online subscription to aggregate news. "& _" No matter what you are in any place, as long as you can access your own subscription. "& _" Fast Go to register: http://www.gbmad.net/rss/ "The above is the HTML text you build, this is sent The email is much better than only text. Don't say that you won't html 'cm.addattachment server.mappath ("test.zip")' If you need to send an attachment, use the above method to add the file in. Cm.send 'Finally, it is of course executing SET CM = Nothing', instantly released the object RESPONSE.WRITE ("Successful Send Mail.")%>
Author Blog:
http://blog.9cbs.net/camelot/