Click to See Complete Forum and Search --> : Please help with email function?


Kevin1
09-23-2003, 01:40 AM
I've been trying to get some help for this one for along time. So far no answers so thought i'd turn to you guys. Heres the problem: I have a function script for email from my website. Its set to when you click on the button "Send site to friend" it fills in the "subject" field and the "message field". Problem is, it works with IE outlook express but not Netscape mail.
Netscape mail is blank entirely. How to get it to work with Netscape I'm lost. Who can help? Heres the function:
function popupMessage() {
// SET MESSAGE VALUES
var to = "";
var cc = "";
var bcc = "";
var subject = "Hey, check out this site!";
var body =
"You gotta check this out! \n\n\tClick on the link below.: \n" +
"\n" +
"\nhttp://www.globalpersonalprotection.com" +
"\n\nSincerely,\n\n" + "Me";

// BUILD MAIL MESSAGE COMPONENTS
var doc = "mailto:" +
"?cc=" + cc +
"&bcc=" + bcc +
"&subject=" + escape(subject) +
"&body=" + escape(body);

// POP UP EMAIL MESSAGE WINDOW
window.location = doc;

Thanks in advance to whomever can tell me how to fix this one!
Kevin1:confused:

pyro
09-23-2003, 08:00 AM
You'll find it will work much better if you use a server side language such as PHP to send email: http://www.webdevfaqs.com/php.php#mailer or try searching the HTML forums for "refer a friend" as I know I've given someone a script that does just that.