Mail Templates

I'm developping a module to send an automatic feedback e-mail to customers. The old version in plain ASP just used an HTML-document and replaced certain fields with the right value. Like {name} for instance with the customer's name.

But I think that in ASP.Net, this is way old-fashioned. I want to use full Web Forms, for example:

MailTemplate1.aspx

<html>
<body>
Hello <span id="customername" runat="server" /><br />
Thank you for your feedback!
</body>
</html>

As you can see, this is a full page and so using a control is not a right solution in my eyes. After all, it is a page, so I want to use a System.Web.UI.Page.

The ThankYouForFeedBack.aspx page would then have to to something like this:

MailTemplate1 MT= new MailTemplate1();
MT.customername.innerText = strCustomerName; // this line will fail, see below
SendMail(strCustomerEmail, I'm developping a module to send an automatic feedback e-mail to customers. The old version in plain ASP just used an HTML-document and replaced certain fields with the right value. Like {name} for instance with the customer's name.

But I think that in ASP.Net, this is way old-fashioned. I want to use full Web Forms, for example:

MailTemplate1.aspx

<html>
<body>
Hello <span id="customername" runat="server" /><br />
Thank you for your feedback!
</body>
</html>

As you can see, this is a full page and so using a control is not a right solution in my eyes. After all, it is a page, so I want to use a System.Web.UI.Page.

The ThankYouForFeedBack.aspx page would then have to to something like this:

MailTemplate1 MT= new MailTemplate1();
MT.customername.innerText = strCustomerName; // this line will fail, see below
SendMail(strCustomerEmail, RenderContents(MT));

It's obvious that I'm looking for the dummy "RenderContents" function. I didn't manage to to it with the Page.Render method, since the page does NOT get loaded if you create a page dynamically like on the first line of code. (Output is thus an empty string) Because of this too, the second line of code WILL PRODUCE AN ERROR, since customername points to nothing because the page doensn't actually get loaded.

Does anyone have an idea?

View Replies


ADVERTISEMENT

ASP Templates

I'm trying to find information on applying CSS to asp Controls. However, all the searches I do relate to ASP.NET 2.0 but I am only using 1.1 (I can't switch to 2.0).

Does anyone have any information or good links to explain how to apply templates or CSS to asp 1.1 controls?

View Replies View Related

Templates

How do they work?phpbb or what ever its called comes with 3 different templates for a user to chose from-they are all totally different with different colours/images/layouts for each style.So how is this done?

View Replies View Related

ASP Templates

I'm looking for a templating system in a Classic ASP environment that works like HTML::Template in Perl. I've actually used HTML::Template with great success in Classic ASP by using the PerlScript engine. PerScript literally brings almost .NET capabilities to Classic ASP.

Unfortunately I am on an assignment right now that precludes the use
of PerlScript -- I have to use VBScript -- and I am sorely missing the templating power of Perl's HTML::Template which allows me to completely decouple ASP scripting and COM+ component coding from HTML output.

If you don't know what I mean by referring to Perl's HTML::Template templating system, then perhaps someone can point me to a free ASP HTML templating system with some power. I've seen some rather simplistic templating VBScript classes that are an improvement over
mixing ASP code and HTML in ASP pages but I've seen nothing that has the power I am looking for yet.

View Replies View Related

Form Templates

I am planning to implement some templates (around 30 templates). User will select this template from the drop down and click print. When it prints it should populate few fields from the form to template and print.

View Replies View Related

Dynamic ASP Templates

I am looking for an example of dynamic ASP templates.

View Replies View Related

Classic ASP And Excel Templates

I am a web developer writing a classic asp website that uses an excel document.

The way it works is that I have pre-filled out excel document sitting on the server that I would like to use as a template excel file.

What is to happen is that a visitor fills out a web form on the website and then the information from the web form is passed to the excel document and the blank spaces are filled in and the excel file is saved on the server.

I can create a blank basic excel document through asp no problems however I am not sure how to open an existing excel file, amend data to it and re save it again.

Also how do i access various cols & rows of the excel file through asp code. this will help me place the form data exactely where the data needs to go in the excel document.

View Replies View Related

HTML Page Templates

Is this affective way using HTML Templates in ASP:

I have html template file with <<TAG1>> .. <<TAGN>> in places, where I want to insert some data then i generate this data in asp:

Dim d ' Create a variable.
Set d = CreateObject("Scripting.Dictionary")
d.Add "TAG1", "Athens" ' Add some keys and items.
d.Add "TAG2", "Belgrade"
d.Add "TAG3", "Cairo"

, open html template, replace each <<TAGx>> with generated data
(d.Item("TAGx") ),
and print it with Response.Write

Or there is any other usual methods to use templates?

View Replies View Related

Trouble With URL To Microsoft Templates

I want a URL links to .dot and .xlt files on my websites. But when users try
to save them it triggers built in template functionallity to save it as .doc
or .xls instead.

How can I publish MS templates and make sure the users get the .dot files
instead of doc files?

View Replies View Related

Send A Mail With Cdosys And Save A Copy In The Sent Mail Folder: How To?

I need some help: with cdosys i'm able to send e-mail from asp using the local exchange
server. Now I also have to save the sent mail into the user's mailbox for future reference: how to?

I'm using:....

View Replies View Related

Mail Insertion Hack On Send Mail Form

I'm using CDO to send mail to the site owner from ASP pages with forms.
Recently one of my forms is occasionally sending email with what seems
to be an insertion which is replacing the plain text part of the email
with something else. Looking at the server sent email source, the
hacked emails have the following:

View Replies View Related

Sending Mail Using ASP/VBScript To Exchange Mail Box

Here's the scenario. I'm currently using cdosys/asp to send mail to
our SMTP server. We use a product called MailFilter to check for SPAM.
It doesn't work very well. If MailFilter isn't working cdosys also has
problems and emails don't get sent. As these email are confirmations
for customer's bookings this means lots of customers calling to see
where their confirmation emails have gone. The root of the problem is
MailFilter but that here to stay. So I had this thought of sending the
message to a queue of some sort so at least they will get to the
customer eventually rather than being lost for good. So here's the
question:

Can I/How do I send messages to a mailbox on our exchange server using
cdo.message?

View Replies View Related

Invalid Mail Address Gives Error In CDO Mail

I'm using CDO from my vb component to fire email. The problem is
whenever one of the email addresses in to, or cc is wrong then none of
the mails are fired even to the correct addresses. It gives an error
like

The server rejected one or more recipient addresses. The server
response was: 550 Relaying denied for <xfd@wre.com>

My code goes like this. Why is the mail server trying to look for the
validation of email ids??I want that atleast the mail should be fired
to the correct email addresses rather than no email fire. Can i
achieve that.

Dim iMsg As New CDO.Message
Dim iConf As New CDO.Configuration


With iConf
.Fields.Item(cdoSendUsingMethod) = cdoSendUsingPort
.Fields.Item(cdoSMTPConnectionTimeout) = 10 ' quick timeout
.Fields.Item(cdoSMTPAuthenticate) = cdoBasic
.Fields.Item(cdoSendUserName) = "username"
.Fields.Item(cdoSendPassword) = "password"
.Fields.Item(cdoURLProxyServer) = "server:80"
.Fields.Item(cdoURLProxyBypass) = "<local>"
.Fields.Item(cdoURLGetLatestVersion) = True
.Fields.Update
End With

Set iMsg.Configuration = iConf
With iMsg
.To = strToEmail
.From = strFromEmail
.CC = strCCEmail
.BCC = strBCCEmail
.Subject = strMailSubject
If strMailFormat = "TEXT" Then
.TextBody = strMailBody
Else
.HTMLBody = strMailBody
End If
If strAttachment <> "" Then
.AddAttachment strAttachment
End If
If intPriority = 2 Then
.Fields.Item("urn:schemas:mailheader:X-Priority") =
cdoHigh
.Fields.Update
End If

.Send
End With

View Replies View Related

Templates For DB-contents And Non-DB-contents

This thread is not so much a big problem, but more to receive comments on my approach. You may have some other tips or advices of where to go or where absolutely not to go with my attempts. Code:

View Replies View Related

Sending E-mail To Different Mail Box!

I would like to know if this can be achieved! On the form I a drop down menu that's called ("Escalation_type") the values are eta, hdtv, and supervisors. I have some ideas but I am not sure if it will work or not. If the use chooses an eta as a value I would like it to be sent a mailbox for exam: no@where.com. If they choose hdtv as value I would like it to be sent to a different mailbox. Can this be achieve by using the case statement or the if statement?

View Replies View Related

Asp Mail Without Using A Mail Component

I'm looking for an asp code who can send an email without using a mail component. I started to write somethings using winsock but I don't have enough time to finish it.

View Replies View Related

Mail And CSS

Have created a contact page which uses CSS and am using asp mail object to send email on the page. However, I have encountered problems and think it might be down to the DOC type that am using ....

View Replies View Related

Mail

I have to create a send mail code after registration had taken place. i want to know how to code for that ....

View Replies View Related

CDO Mail From ASP On IIS 6

Our company has recently migrated from Windows 2000
servers to Windows 2003 servers. Since the move to IIS 6,
I have been unsuccessful in finding how to configure the
server to support CDONTS to send smtp mail.

I have used this method in asp pages for years without
any issues, until 2003 server. I have even tried opening
the smtp server completely, and still no luck. I can send
mail using OE through the server, so I don't believe it's
an smtp configuration issue.

View Replies View Related

Mail Through ASP

I am facing a problem,
I am using CDONTS for mailing,
and the following Code:
<%
set sendMail=server.CreateObject("CDONTS.NewMail")
sendMail.To="divyesh.shah@softsolvers.com"
sendMail.Body="Hello Testing"
sendMail.From="divyesh.shah@softsolvers.com"
sendMail.Subject ="Test"
sendMail.BodyFormat =0
if sendMail.Send then
Response.Write ("Mail Send")
else
Response.Write ("Mail Not Send")
end if
set sendMail=nothing

%>
I have two windows 2000 server, while running from one server i got the mail, while from the other i don't got the mail,on the second one the mail is dump in the mailrootqueue.
is there is some problem with the CDONTS setting on the second server, or some other problem

View Replies View Related

Mail Api For ASP

I have a simple ASP app (not ASP.Net) that I need to send email from.
Can anyone make a recommendation, and share why that's the best one?
(cdo, msxml, etc)

View Replies View Related

Cdo Mail

I am trying to get cdo.message working on my home development machine,
however, when I send it it appears to get stuck in the queue and never
actually gets sent.

If I don't have a domain SMTP set (either alias or remote) then I get an
error on page. But if I set these, the email just sits on the queue. I have
been trying to work it out from other posts and forums, aspFAQ etc but with
no joy.

Could someone supply a step by step guide to getting SMTP set up on a win2K
pro machine and how to get these mails out of my servers queue and into the
outside world so I can properly test code withing having to upload to my
hosts server and get the email back?

View Replies View Related

Asp Mail

We use a custom built mail system at work. It is an asp based webmailing system. It uses cdonts.When we try to mailout to our clients (as a group) about 1500 of them, most of them get the full email. Others get about a third of the email.

View Replies View Related

Mail In ASP

how can i send the mail to multiple receipients like yahoo.mail or hotmail.

View Replies View Related

ASP Mail

I made a form in which I send the visitor a link to my page but when the visitor gets that link in the mail it dosent send him to the page just says invalid syntax or something like outbound. I'm not trying to spam

this is the code iput into body variable

text= "<table width='310' border='0'> "&_
"<tr><td class='all'><p align='center'> Something <br>"&_
"something<br>"&_
" Something<br>"&_
" <strongAnd something <br>"&_
" </strong>Something!<br>"&_
" <a href='http//www.something.com'>www.something.com</a></p>
</td></tr> </table>"

I looked at code that works and its the same why dosent this work.

View Replies View Related

Mail With ASP

I was wondering what is the best method for mailing with asp? There is CDONTS and ASP MAIL and something else. What do you guys recommend?

I want to send my mailing list of 315 (its a celebrity gossip ezine) by html/graphic way. SO when a user checks their hotmail, they SEE the html message (I think this is called "in-line viewing" and not to have it come as attachments. Is there any script I can run and try out on PWS?

View Replies View Related

Receiving Mail

I am generating Purchase Order from database. Then i send it to the
supplier. I am using CDONTS to send mail.
I am not sure that it was sent or not.
So i need confirmation when they read it or received. How can i send a mail
with acknowledgement?

View Replies View Related

ASP E-mail Question

My mail server and web server are 2 different servers.

Both servers run win2k.

Therefore the web server does not have an SMPT server.

ASP throws the Server.CreateObject failed error when using a CDONT.NewMail object.

What I need to be able to do is configure IIS or ASP on the web server to look at the mail server for the SMTP server.

Is this possible? If so, how is IIS/ASP configured for this?

View Replies View Related

Mail Script

I'm trying to create a mail script "not formmail" to email me a test message using asp. Could somebody tell me what's wrong with me script? it doesn't send me a message???. I'm using windows 2000 & mailenable email server.

<%@ Language=VBScript %>
<%
Dim objCDO
Set objCDO = Server.CreateObject("CDONTS.NEWMAIL")
objCDO.To = "4@yahoo.com"
objCDO.From = "4@yahoo.com"
objCDO.cc = ""
Dim txtSubject
txtSubject = "Test Test Test"
objCDO.Subject = "Testing Email Script"
objCDO.Body = txtSubject
objCDO.Send
%>
<html>
<head>
<title>Comersus Diagnostics and Tools</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>

<body bgcolor="#FFFFFF">
<img src="images/logocomersus.gif" width="194" height="57">
<br><br><b>Comersus Diagnostics and Tools</b> <br><br>
<body>

</body>
</html>

View Replies View Related

Junk Mail

I created an Email sender to get emails out of my database, and send it! But when they get the Email it goes into Junk Mail, which most people dont read. Just wondering is there a way of sending the Email, and for it to NOT go into junk mail?

View Replies View Related

Form To E-mail

I have an html page with a form on it. I need the information that a user fills into the form to be sent to an email address via an asp file....

View Replies View Related

Format E-mail

I use an ASP mail object to send orders filled online to a recipient via an e-mail. I would like to know if it's possible to format the way the order looks in an e-mail? I tried the following, but see no change in the format:

H1 = "<b><font size=2 color=#ED171F face=Verdana, Arial, Helvetica,
sans-serif>Order Type:</font></b>"

StrBody = H1 + Request(OrderNum) + vbCrLf

Then I get Order Type: just as plain as it would come if it didn't have any formatting.

If I do the following:

StrBody = "<b>Order Type:</b> + Request(OrderNum) + vbCrLf

Then I get <b>OrderType:</b> as the heading.

Does anyone know if it's possible to format the way the text look in an e-mail that is sent using the ASP Mail Object? Is there a different way of controlling the format/appearance of the text that appears in an e-mail?

View Replies View Related

How To Send Mail

I have the code for the sending mail but i do not know to loop it. I have been given specification saying that i should send mail after registration and deregistration.

so i have a asp page given the action function of the register form so the page updates the registration done. so i given after registration the send mail code and want to have the loop or condition for the mail to be sent to the person who updates registeration
and code is as follows....

<%@ Language=VBScript %>
<HTML>
<HEAD>
<META NAME="GENERATOR" Content="Microsoft Visual Studio 6.0">
</HEAD>
<BODY> .....

View Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved