Can i send an email from JavaScript? 
January 24th, 2007, 10:35 AM
| | | |
Can i send an email from JavaScript? Is it possible? If yes please the
code to send email using javascript... | 
January 24th, 2007, 10:45 AM
| | | | re: Can i send an email from JavaScript?
Mahernoz wrote on 24 jan 2007 in comp.lang.javascript : Quote:
Can i send an email from JavaScript? Is it possible? If yes please the
code to send email using javascript...
| Depending on browser setting and email client:
<button
onclick="mailto:my@self.xyz?subject=hi&body=ha">
send
</button>
With serverside javascript the possibilities are many.
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress) | 
January 24th, 2007, 11:25 AM
| | | | re: Can i send an email from JavaScript?
Hi,
Thanks for your answer....
ok agreed that this can send email...but is it possible to send email
without using outlook... i still have to use outlook to click the send
button.... can i send this email without using outlook... i hope you
understand the scenario
Regards,
Mahernoz
On Jan 24, 3:38 pm, "Evertjan." <exjxw.hannivo...@interxnl.netwrote: Quote:
Mahernoz wrote on 24 jan 2007 in comp.lang.javascript:
> Quote:
Can i send an email from JavaScript? Is it possible? If yes please the
code to send email using javascript...Depending on browser setting and email client:
| >
<button
onclick="mailto:m...@self.xyz?subject=hi&body=ha">
send
</button>
>
With serverside javascript the possibilities are many.
>
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
| | 
January 24th, 2007, 12:25 PM
| | | | re: Can i send an email from JavaScript?
Mahernoz wrote on 24 jan 2007 in comp.lang.javascript : Quote:
On Jan 24, 3:38 pm, "Evertjan." <exjxw.hannivo...@interxnl.netwrote: Quote:
>Mahernoz wrote on 24 jan 2007 in comp.lang.javascript:
>> Quote:
Can i send an email from JavaScript? Is it possible? If yes please
the code to send email using javascript...Depending on browser
setting and email client:
| >>
><button
>onclick="mailto:m...@self.xyz?subject=hi&body=ha" >
>send
></button>
>>
>With serverside javascript the possibilities are many.
| | [Please do not toppost on usenet] Quote:
Thanks for your answer....
ok agreed that this can send email...but is it possible to send email
without using outlook...
| Off course you can.
I never used Outlook, using Pegasus since 1996. Quote:
i still have to use outlook to click the send
button.... can i send this email without using outlook... i hope you
understand the scenario
| Please stop thinking Outlook! There are many othe ways of using email.
Automated email transmission from clientside web page needs some form of
acknoledgement from the user. Or would you like that by browsing a page
a mail is sent from your computer without your intervention?
Compromizing [bad, bad, bad] browser security settings, you can execute
any command line as a shell command. There are many small command line
email clients that will do that.
Serverside, depending on the server's configuraton, you can do what you
like! [and that is my choice, done it many a time]
Do you understand the difference between serverside and clientside code?
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress) | 
January 24th, 2007, 12:35 PM
| | | | re: Can i send an email from JavaScript?
Hi Sir,
Yes i do understand the difference between server side and client side
code.... but the fact is i myself want to have this unsecured
behavior.... i want an application like this... i want to write in a
page_load event a script that when the page_load happens an email is
sent to me.... i will send this page as an email... so that when the
guy opens the email i am notified about it! In the email i naturally
cannot use any scripts...? can i do this by clientside or serverside
code? any idea? That's why i needed this unsecured behavior....
Is there a way by which i can do this...? I am preparing an Email Read
Notification System similar to ReadNotify.com and any approach like
clientside or serverside is acceptable....
Regards,
Mahernoz
On Jan 24, 5:16 pm, "Evertjan." <exjxw.hannivo...@interxnl.netwrote: Quote:
Mahernoz wrote on 24 jan 2007 in comp.lang.javascript:
> Quote:
On Jan 24, 3:38 pm, "Evertjan." <exjxw.hannivo...@interxnl.netwrote: Quote: |
Mahernoz wrote on 24 jan 2007 in comp.lang.javascript:
| | > Quote: Quote:
Can i send an email from JavaScript? Is it possible? If yes please
the code to send email using javascript...Depending on browser
setting and email client:
| | > Quote: Quote:
<button
onclick="mailto:m...@self.xyz?subject=hi&body=ha">
send
</button>
| | > Quote: Quote: |
With serverside javascript the possibilities are many.[Please do not toppost on usenet]
| | > Quote:
Thanks for your answer....
ok agreed that this can send email...but is it possible to send email
without using outlook...Off course you can.
| >
I never used Outlook, using Pegasus since 1996.
> Quote:
i still have to use outlook to click the send
button.... can i send this email without using outlook... i hope you
understand the scenarioPlease stop thinking Outlook! There are many othe ways of using email.
| >
Automated email transmission from clientside web page needs some form of
acknoledgement from the user. Or would you like that by browsing a page
a mail is sent from your computer without your intervention?
>
Compromizing [bad, bad, bad] browser security settings, you can execute
any command line as a shell command. There are many small command line
email clients that will do that.
>
Serverside, depending on the server's configuraton, you can do what you
like! [and that is my choice, done it many a time]
>
Do you understand the difference between serverside and clientside code?
>
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
| | 
January 24th, 2007, 12:45 PM
| | | | re: Can i send an email from JavaScript?
Mahernoz wrote on 24 jan 2007 in comp.lang.javascript : Quote:
Yes i do understand the difference between server side and client side
>
| [Please do not toppost on usenet]
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress) | 
January 24th, 2007, 12:55 PM
| | | | re: Can i send an email from JavaScript?
I am not clear about your previous message [Please do not toppost on
usenet]... what does it mean?
Regards,
Mahernoz
On Jan 24, 5:35 pm, "Evertjan." <exjxw.hannivo...@interxnl.netwrote: Quote:
Mahernoz wrote on 24 jan 2007 in comp.lang.javascript:
> Quote: |
Yes i do understand the difference between server side and client side[Please do not toppost on usenet]
| >
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
| | 
January 24th, 2007, 02:35 PM
| | | | re: Can i send an email from JavaScript?
Mahernoz wrote: Quote:
I am not clear about your previous message [Please do not toppost
on usenet]... what does it mean?
>
| It means "do not post *on* *top* of other messages.
Note that my reply is *below* your message, but that my reply and your
message are both *on* *top* of the message from Evertjan that you were
replying to. This is what "top-posting" means.
To make messages easier to read, always add your reply *below* the
message you are replying to. Quote:
On Jan 24, 5:35 pm, "Evertjan." <exjxw.hannivo...@interxnl.net>
wrote: Quote:
>Mahernoz wrote on 24 jan 2007 in comp.lang.javascript:
>> Quote:
>>Yes i do understand the difference between server side and
>>client side[Please do not toppost on usenet]
| >-- Evertjan. The Netherlands. (Please change the x'es to dots in
>my emailaddress)
| >
| | 
January 24th, 2007, 03:05 PM
| | | | re: Can i send an email from JavaScript?
On 24 Jan., 13:22, "Mahernoz" <maher...@gmail.comwrote: Quote:
Hi Sir,
Yes i do understand the difference between server side and client side
code.... but the fact is i myself want to have this unsecured
behavior.... i want an application like this... i want to write in a
page_load event a script that when the page_load happens an email is
sent to me.... i will send this page as an email... so that when the
guy opens the email i am notified about it! In the email i naturally
cannot use any scripts...? can i do this by clientside or serverside
code? any idea? That's why i needed this unsecured behavior....
>
Is there a way by which i can do this...? I am preparing an Email Read
Notification System similar to ReadNotify.com and any approach like
clientside or serverside is acceptable....
>
Regards,
Mahernoz
>
On Jan 24, 5:16 pm, "Evertjan." <exjxw.hannivo...@interxnl.netwrote:
> Quote: |
Mahernoz wrote on 24 jan 2007 in comp.lang.javascript:
| > Quote: Quote:
On Jan 24, 3:38 pm, "Evertjan." <exjxw.hannivo...@interxnl.netwrote:
>Mahernoz wrote on 24 jan 2007 in comp.lang.javascript:
| | > Quote: Quote:
Can i send an email from JavaScript? Is it possible? If yes please
the code to send email using javascript...Depending on browser
setting and email client:
| | > Quote: Quote:
><button
>onclick="mailto:m...@self.xyz?subject=hi&body=ha" >
>send
></button>
| | > Quote: Quote: |
>With serverside javascript the possibilities are many.[Please do not toppost on usenet]
| | > Quote: Quote:
Thanks for your answer....
ok agreed that this can send email...but is it possible to send email
without using outlook...Off course you can.
| | > Quote: |
I never used Outlook, using Pegasus since 1996.
| > Quote: Quote:
i still have to use outlook to click the send
button.... can i send this email without using outlook... i hope you
understand the scenarioPlease stop thinking Outlook! There are many othe ways of using email.
| | > Quote:
Automated email transmission from clientside web page needs some form of
acknoledgement from the user. Or would you like that by browsing a page
a mail is sent from your computer without your intervention?
| > Quote:
Compromizing [bad, bad, bad] browser security settings, you can execute
any command line as a shell command. There are many small command line
email clients that will do that.
| > Quote:
Serverside, depending on the server's configuraton, you can do what you
like! [and that is my choice, done it many a time]
| > Quote: |
Do you understand the difference between serverside and clientside code?
| > Quote:
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
| | This is no problem: What about :
onload = function() {
UniAjax.request({
uri: 'sendMail.php',
method: 'post',
arguments: {
bodysHTML: document.body.innerHTML
}
});
}
So this little function sends an Ajax request to a PHP file on your
server. This file contains a little function that sends a mail to you.
You can't send a mail from client side directly. If you PHP Server and
use Ajax - no problem. UniAjax.request is a method you find in UniAjax
- an Ajax framework. More about it: http://uniajax.net
The PHP file 'sendMail.php' looks like this
<?php
@mail('yourmailaddress@domain.com', 'subject', $_POST['bodysHTML']);
?>
This should work -more about mail: http://www.php.net/manual/de/ref.mail.php
Andi | 
January 27th, 2007, 06:05 AM
| | | | re: Can i send an email from JavaScript?
Hi Friends,
Thanks for all your support...
All of my friends, Please don't be negative thinkers... be positive in
your approach towards the solution... the solution is very easy i found
it... please look at this article... http://www.anupshinde.com/articles/H...Mail-Receipts/
Regards,
Mahernoz
On Jan 24, 7:54 pm, "webEater" <andreaskal...@gmx.dewrote: Quote:
On 24 Jan., 13:22, "Mahernoz" <maher...@gmail.comwrote:
>
>
> Quote:
Hi Sir,
Yes i do understand the difference between server side and client side
code.... but the fact is i myself want to have this unsecured
behavior.... i want an application like this... i want to write in a
page_load event a script that when the page_load happens an email is
sent to me.... i will send this page as an email... so that when the
guy opens the email i am notified about it! In the email i naturally
cannot use any scripts...? can i do this by clientside or serverside
code? any idea? That's why i needed this unsecured behavior....
| > Quote:
Is there a way by which i can do this...? I am preparing an Email Read
Notification System similar to ReadNotify.com and any approach like
clientside or serverside is acceptable....
| >> Quote: |
On Jan 24, 5:16 pm, "Evertjan." <exjxw.hannivo...@interxnl.netwrote:
| > Quote: Quote: |
>Mahernozwrote on 24 jan 2007 in comp.lang.javascript:
| | > Quote: Quote:
On Jan 24, 3:38 pm, "Evertjan." <exjxw.hannivo...@interxnl.netwrote:
>Mahernozwrote on 24 jan 2007 in comp.lang.javascript:
| | > Quote: Quote:
Can i send an email from JavaScript? Is it possible? If yes please
the code to send email using javascript...Depending on browser
setting and email client:
| | > Quote: Quote:
<button
onclick="mailto:m...@self.xyz?subject=hi&body=ha">
send
</button>
| | > Quote: Quote: |
With serverside javascript the possibilities are many.[Please do not toppost on usenet]
| | > Quote: Quote:
Thanks for your answer....
ok agreed that this can send email...but is it possible to send email
without using outlook...Off course you can.
| | > Quote: Quote: |
I never used Outlook, using Pegasus since 1996.
| | > Quote: Quote:
i still have to use outlook to click the send
button.... can i send this email without using outlook... i hope you
understand the scenarioPlease stop thinking Outlook! There are many othe ways of using email.
| | > Quote: Quote:
Automated email transmission from clientside web page needs some form of
acknoledgement from the user. Or would you like that by browsing a page
a mail is sent from your computer without your intervention?
| | > Quote: Quote:
Compromizing [bad, bad, bad] browser security settings, you can execute
any command line as a shell command. There are many small command line
email clients that will do that.
| | > Quote: Quote:
Serverside, depending on the server's configuraton, you can do what you
like! [and that is my choice, done it many a time]
| | > Quote: Quote: |
Do you understand the difference between serverside and clientside code?
| | > Quote: Quote:
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)This is no problem: What about:
| | >
onload = function() {
UniAjax.request({
uri: 'sendMail.php',
method: 'post',
arguments: {
bodysHTML: document.body.innerHTML
}
});
>
}So this little function sends an Ajax request to a PHP file on your
server. This file contains a little function that sends a mail to you.
You can't send a mail from client side directly. If you PHP Server and
use Ajax - no problem. UniAjax.request is a method you find in UniAjax
- an Ajax framework. More about it:http://uniajax.net
>
The PHP file 'sendMail.php' looks like this
>
<?php
@mail('yourmailaddr...@domain.com', 'subject', $_POST['bodysHTML']);
?>
>
This should work -more about mail:http://www.php.net/manual/de/ref.mail.php
>
Andi
| |  | | | | /bytes/about
We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights.
Get the best answers to your questions from over 225,720 network members.
|