473,395 Members | 1,383 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Email the content of an ASP page using the email client

Hi,

Thanks in advance for any help you can provide. I have a frameset and
one of the frames contains a page that is created on the fly, an
actual word document. I want to have a button in one of the other
frames that emails this created page as an email attachment using the
email client (outlook or whatever). I created a function as follows:

<script language="JavaScript">
function mailIt()
var page = parent.QandA;
document.write 'mailto: se******@example.com?subject=The
document&Attachment=';
document.write page;
}
</script>
Which is then called from a button, but it doesnt work! QandA is the
name of the frame that contains the document I want to email as the
attachment. Can anyone help please??!
Thanks
Jul 20 '05 #1
9 1639
In article <7d**************************@posting.google.com >,
ni*********@hotmail.com says...
Hi,

Thanks in advance for any help you can provide. I have a frameset and
one of the frames contains a page that is created on the fly, an
actual word document. I want to have a button in one of the other
frames that emails this created page as an email attachment using the
email client (outlook or whatever). I created a function as follows:

<script language="JavaScript">
function mailIt()
var page = parent.QandA;
document.write 'mailto: se******@example.com?subject=The
document&Attachment=';
document.write page;
}
</script>
Which is then called from a button, but it doesnt work! QandA is the
name of the frame that contains the document I want to email as the
attachment. Can anyone help please??!


Use a server-side process to do it. Your example mailto: code above is
faulty.

--
Hywel I do not eat quiche
http://hyweljenkins.co.uk/
http://hyweljenkins.co.uk/mfaq.php
Jul 20 '05 #2
Hywel Jenkins <hy**********@hotmail.com> wrote in message news:<MP************************@news.individual.n et>...
In article <7d**************************@posting.google.com >,
ni*********@hotmail.com says...
Hi,

Thanks in advance for any help you can provide. I have a frameset and
one of the frames contains a page that is created on the fly, an
actual word document. I want to have a button in one of the other
frames that emails this created page as an email attachment using the
email client (outlook or whatever). I created a function as follows:

<script language="JavaScript">
function mailIt()
var page = parent.QandA;
document.write 'mailto: se******@example.com?subject=The
document&Attachment=';
document.write page;
}
</script>
Which is then called from a button, but it doesnt work! QandA is the
name of the frame that contains the document I want to email as the
attachment. Can anyone help please??!


Use a server-side process to do it. Your example mailto: code above is
faulty.

Thanks for your help. Any ideas as to what the code should be? I still
cant get it to work :(
Jul 20 '05 #3
In article <7d**************************@posting.google.com >,
ni*********@hotmail.com enlightened us with...
Which is then called from a button, but it doesnt work! QandA is the
name of the frame that contains the document I want to email as the
attachment. Can anyone help please??!


Use a server-side process to do it. Your example mailto: code above is
faulty.

Thanks for your help. Any ideas as to what the code should be? I still
cant get it to work :(


Do you have ASP CDONTS?
http://www.codefixer.com/tutorials/email_cdonts.asp

Any more questions on ASP should be directed to the ASP groups over at
msnews.microsoft.com.

If you have JSP or PHP, I have code to mail with either of those, too.

--
--
~kaeli~
A little rudeness and disrespect can elevate a meaningless
interaction to a battle of wills and add drama to an
otherwise dull day.
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace

Jul 20 '05 #4
In article <7d**************************@posting.google.com >,
ni*********@hotmail.com says...
Hywel Jenkins <hy**********@hotmail.com> wrote in message news:<MP************************@news.individual.n et>...
In article <7d**************************@posting.google.com >,
ni*********@hotmail.com says...
<script language="JavaScript">
function mailIt()
var page = parent.QandA;
document.write 'mailto: se******@example.com?subject=The
document&Attachment=';
document.write page;
}
</script>

Use a server-side process to do it. Your example mailto: code above is
faulty.

Thanks for your help. Any ideas as to what the code should be? I still
cant get it to work :(


You can't add a subject and an attachment with mailto - just set the
recipient. I have no idea what the ASP code for a form handler that
would suit you, but you're barking way up the wrong tree with what
you've got.

--
Hywel I do not eat quiche
http://hyweljenkins.co.uk/
http://hyweljenkins.co.uk/mfaq.php
Jul 20 '05 #5

Do you have a mail component available to you on your server ... such
as ASPEmail, CDONTs, or something ... if so, tell me, and I will
supply you with a subroutine to use for the email.

Brynn
www.coolpier.com


On 7 Jan 2004 07:18:52 -0800, ni*********@hotmail.com (NickH) wrote:
Hi,

Thanks in advance for any help you can provide. I have a frameset and
one of the frames contains a page that is created on the fly, an
actual word document. I want to have a button in one of the other
frames that emails this created page as an email attachment using the
email client (outlook or whatever). I created a function as follows:

<script language="JavaScript">
function mailIt()
var page = parent.QandA;
document.write 'mailto: se******@example.com?subject=The
document&Attachment=';
document.write page;
}
</script>
Which is then called from a button, but it doesnt work! QandA is the
name of the frame that contains the document I want to email as the
attachment. Can anyone help please??!
Thanks


Brynn
www.coolpier.com

I participate in the group to help give examples of code.
I do not guarantee the effects of any code posted.
Test all code before use!
Jul 20 '05 #6
z@z.com (Brynn) wrote in message news:<40**************@news.comcast.giganews.com>. ..
Do you have a mail component available to you on your server ... such
as ASPEmail, CDONTs, or something ... if so, tell me, and I will
supply you with a subroutine to use for the email.

Brynn
www.coolpier.com


On 7 Jan 2004 07:18:52 -0800, ni*********@hotmail.com (NickH) wrote:
Hi,

Thanks in advance for any help you can provide. I have a frameset and
one of the frames contains a page that is created on the fly, an
actual word document. I want to have a button in one of the other
frames that emails this created page as an email attachment using the
email client (outlook or whatever). I created a function as follows:

<script language="JavaScript">
function mailIt()
var page = parent.QandA;
document.write 'mailto: se******@example.com?subject=The
document&Attachment=';
document.write page;
}
</script>
Which is then called from a button, but it doesnt work! QandA is the
name of the frame that contains the document I want to email as the
attachment. Can anyone help please??!
Thanks


Brynn
www.coolpier.com

I participate in the group to help give examples of code.
I do not guarantee the effects of any code posted.
Test all code before use!

Hi Brynn

The server has the CDONTS mail component. Thanks for any help!

Nick
Jul 20 '05 #7
Checkout the microsoft.public.inetserver.asp.general group for a post
called ... Email_Handler.asp

It will be up in a few minutes

Brynn


On 21 Jan 2004 23:59:17 -0800, ni*********@hotmail.com (NickH) wrote:
z@z.com (Brynn) wrote in message news:<40**************@news.comcast.giganews.com>. ..
Do you have a mail component available to you on your server ... such
as ASPEmail, CDONTs, or something ... if so, tell me, and I will
supply you with a subroutine to use for the email.

Brynn
www.coolpier.com


On 7 Jan 2004 07:18:52 -0800, ni*********@hotmail.com (NickH) wrote:
>Hi,
>
>Thanks in advance for any help you can provide. I have a frameset and
>one of the frames contains a page that is created on the fly, an
>actual word document. I want to have a button in one of the other
>frames that emails this created page as an email attachment using the
>email client (outlook or whatever). I created a function as follows:
>
><script language="JavaScript">
>function mailIt()
> var page = parent.QandA;
> document.write 'mailto: se******@example.com?subject=The
>document&Attachment=';
> document.write page;
> }
></script>
>Which is then called from a button, but it doesnt work! QandA is the
>name of the frame that contains the document I want to email as the
>attachment. Can anyone help please??!
>Thanks


Brynn
www.coolpier.com

I participate in the group to help give examples of code.
I do not guarantee the effects of any code posted.
Test all code before use!

Hi Brynn

The server has the CDONTS mail component. Thanks for any help!

Nick


Brynn
www.coolpier.com

I participate in the group to help give examples of code.
I do not guarantee the effects of any code posted.
Test all code before use!
Jul 20 '05 #8
Hywel Jenkins wrote:
You can't add a subject and an attachment with mailto [...]


In fact, you *can* add a Subject, that header is believed to
be safe along with Keywords and Body:

http://www.ietf.org/rfc/rfc2368.txt

The problem is buggy implementations. You are right for the
attachment, however, and thus the server-side app is the best
bet (not to mention people who do not use a mail client whose
numbers are apparently increasing.)
PointedEars
Jul 20 '05 #9
Thomas 'PointedEars' Lahn wrote:
Hywel Jenkins wrote:

You can't add a subject and an attachment with mailto [...]

In fact, you *can* add a Subject, that header is believed to
be safe along with Keywords and Body:

http://www.ietf.org/rfc/rfc2368.txt

The problem is buggy implementations. You are right for the
attachment, however, and thus the server-side app is the best
bet (not to mention people who do not use a mail client whose
numbers are apparently increasing.)


And its the lack of a default mail client that will cause mailto: to be
as unreliable as it is. Of all the browsers I have installed, the only
one that has a default mail client is AOL and thats because I can't
disable it.

--
Randy
Chance Favors The Prepared Mind

Jul 20 '05 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: lucanos | last post by:
Hey All, I'm having trouble trying to create a PHP file which will generate a multipart email message (containing both an HTML formatted part and a Plain Text formatted part). I have Googled...
0
by: James Hong | last post by:
Help please, I try to sending an email from my html page using the java applet. but it give error on most of the PC only very few work, what is the error i make the java applet show as below ...
88
by: Mike | last post by:
Is there a way to determine what a user's default email client is? I read a post from 3 years ago that said no. I guess I'm hoping something has come along since then.
24
by: Arno R | last post by:
Hi all, I have a client with several shoe-shops. Customers can leave their email-address if they want to be notified when there is a sale. Input is validated with instr() I am checking for @...
5
by: Das | last post by:
Hi, I'm trying to email html page & that page also contains the images. I can do that when we send html page from ms outlook. But I want to attach page c# code & send the mail through smtp mail....
7
by: Martin | last post by:
Hi, I have a standard aspx page (form) that contains a few user controls. Upon form submission the page is validated. If validation passses then a text based email is sent. This is all working...
13
by: =?Utf-8?B?S2VzdGZpZWxk?= | last post by:
Hi Our company has a .Net web service that, when called via asp.net web pages across our network works 100%! The problem is that when we try and call the web service from a remote machine, one...
0
by: anu b | last post by:
Now i am sending email to my friend using session variable... but my code is as below private bool SendEmail(string email) { try {
3
by: anu b | last post by:
Hii I am using System.net.mail for sending email... i need to send a webpage with its html content as my email body .....for that i used mail.Isbodyhtml as true...but it is not working for me...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.