473,396 Members | 1,590 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,396 software developers and data experts.

sending mail using javascript

hi

I'm would like my app to send a preformatted email(with subject and
body) everytime a user pushed a button, like : onclick "
mailto:th**@that.com" , without the user seeing anything, i.e. not
being able to edit the message.

Using php, this is very simple; mail("th**@example.com", "Subject",
"Line 1\nLine 2\nLine 3");

is there a way to do this the same, easy way using javascript?
obscurr
Jul 20 '05 #1
4 36693
ob*****@hotmail.com (Obscurr) writes:
I'm would like my app to send a preformatted email(with subject and
body) everytime a user pushed a button, like : onclick "
mailto:th**@that.com" , without the user seeing anything, i.e. not
being able to edit the message. is there a way to do this the same, easy way using javascript?


No. Plain Javascript has no networking ability besides what the
browser provides. You can make the browser fetch an URL, and that is
about it.

Using the mailto: protocol requires the user to have set up a mail
client, and will usually open that client for him to see and approve.

When you think about it, if what you want was possible, you could make
a page that sends spam mail every time someone visits it ... without
him even being aware.

/L
--
Lasse Reichstein Nielsen - lr*@hotpop.com
Art D'HTML: <URL:http://www.infimum.dk/HTML/randomArtSplit.html>
'Faith without judgement merely degrades the spirit divine.'
Jul 20 '05 #2
Best way to do mailing is serverside as mailto loads up your default mail
client in browsers like NS and even worse message if you don't have a
default set up.
So, as I said, best way is server side.

Stu

"Obscurr" <ob*****@hotmail.com> wrote in message
news:44**************************@posting.google.c om...
hi

I'm would like my app to send a preformatted email(with subject and
body) everytime a user pushed a button, like : onclick "
mailto:th**@that.com" , without the user seeing anything, i.e. not
being able to edit the message.

Using php, this is very simple; mail("th**@example.com", "Subject",
"Line 1\nLine 2\nLine 3");

is there a way to do this the same, easy way using javascript?
obscurr

Jul 20 '05 #3
In article <44**************************@posting.google.com >,
ob*****@hotmail.com says...
hi

I'm would like my app to send a preformatted email(with subject and
body) everytime a user pushed a button, like : onclick "
mailto:th**@that.com" , without the user seeing anything, i.e. not
being able to edit the message.

Using php, this is very simple; mail("th**@example.com", "Subject",
"Line 1\nLine 2\nLine 3");

is there a way to do this the same, easy way using javascript?

Yes - do you have server-side JavaScript or ASP with JavaScript?

--
Hywel
Jul 20 '05 #4
Hywel Jenkins <hy**********@hotmail.com> wrote in message news:<MP***********************@news.individual.ne t>...
In article <44**************************@posting.google.com >,
ob*****@hotmail.com says...
hi

I'm would like my app to send a preformatted email(with subject and
body) everytime a user pushed a button, like : onclick "
mailto:th**@that.com" , without the user seeing anything, i.e. not
being able to edit the message.

Using php, this is very simple; mail("th**@example.com", "Subject",
"Line 1\nLine 2\nLine 3");

is there a way to do this the same, easy way using javascript?

Yes - do you have server-side JavaScript or ASP with JavaScript?

yes I have server-side Javascript. How do I progress?

obscurr
Jul 20 '05 #5

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

Similar topics

2
by: Mr. x | last post by:
Hello, I am sending emails with Hebrew contents. When receiving emails - I cannot see the Hebrew characters (it is not outlook express configuration, because when receiving emails from friends -...
9
by: B-Dog | last post by:
I've built a small app that sends mail through our ISP's SMTP server but when I try to send through my local exchange server I get CDO error. Does webmail use SMTP or does it strictly rely on...
1
by: Eric Sheu | last post by:
Greetings, I have been searching the web like mad for a solution to my SMTP problem. I am using Windows Server 2003 and ASP.NET 2.0 w/ C# to send out e-mails from a web site I have created to...
4
by: k.visube | last post by:
In my ASP application,i need to send a formatted text mail (i.e with newline characters). here in my application i used a function in javascript which construts the mail body sample snippet ...
3
by: mfleet1973 | last post by:
Hello Again. I have a program that sends e-mails as follows: Try Dim mail As New MailMessage mail.To = "me@comp.com" mail.From = "me@comp.com mail.Subject = "Test" mail.Body = "Testing123"
6
by: prash.marne | last post by:
hi all , this is a very simple problem but i need some help, My situation is : i have a form which opens in a pop-up window , in which user will insert his email-id & name , there are two...
2
by: Oltmans | last post by:
Hi All, I'm trying to send an HTML email from my asp.net 2.0 application. I want to show an "alert" message when user opens up my email message using JavaScript. Though I've been able to send...
3
by: shybe | last post by:
I have a send mail script on my site that. The emails are recieved by gmail, and yahoo, but not to mail clients like Outlook, Mail, etc...) Is this a problem with the script, or is it...
2
ThatThatGuy
by: ThatThatGuy | last post by:
Hello reader,, This might be a very simple question, but what to just say about it, i'm facing it Actually i'm developing a web App and i want email feature in that.... I'm sending mail from my...
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:
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
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
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
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
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...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

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.