Hello,

I am using the PHP Mailer by 88Kilo in the movies section.
http://www.flashkit.com/movies/Inter...1390/index.php

However, I had to change it so that the comments box had a scroll bar. To do this, I had to put the comments input text box, which is labeled Var:comments into a separate movie clip. Now it scrolls and my email sends, but it doesn't send anything you type in the comments box. I think there is a problem with my routing...somehow I need to tell the mailer to look within the movie clip (instance name: myInput) for the Var:comments.

Here is the code in the actions layer on the root timeline:

stop();
// this variable will decide if the email address is in the correct format
a =0;
// validates the email field for @ symbol and a . at the end
function validate () {
if (from.length>=7) {
if (from.indexOf("@")>0) {
if ((from.indexOf("@")+2)<from.lastIndexOf(".")) {
if (from.lastIndexOf(".")<(from.length-2)) {
a = 1;
// email is fine
}
}
}
}

}
// checks for empty fields then calls email check function
function formcheck () {
validate ();
trace(a);
if (fname = "" or telno eq "" or comments eq "" or from eq "") {
stop();
error = "You have left blank fields, please fill in all fields, thank you";
} else {
emailcheck ();
}
}
// email check function calls the fucntion at the top, if its satisfied it loads the php script and sends you to frame 2
function emailcheck (){
if (a != 1){
stop();
error = "Email address not valid";
} else {
loadVariablesNum("mail.php3", 0, "POST");
gotoAndStop(2);
}
}

Here is the code from the .php page:

<?php

$adminaddress = "[email protected]";
$sitename = "Website.com";

mail("$adminaddress","Info Request",

"A Message from $sitename from\n

First Name: $name

Company Name: $company
Telephone: $telno

Email: $from\n

The visitor commented:

-----------------------------------------------------------------------------------------

$comments



Logged Info :

-----------------------------------------------------------------------------------------

Using: $HTTP_USER_AGENT

Hostname: $ip

IP address: $REMOTE_ADDR

Date/Time: $date","FROM:$adminaddress");


?>

Any help is greatly appreciated.

PippyLu