# Contact form with userid input instead of email... please help!

**URL:** <https://forum.kirupa.com/t/contact-form-with-userid-input-instead-of-email-please-help/182189>\
**Category:** Uncategorized\
**Created:** [March 16, 2006, 3:41am UTC](https://forum.kirupa.com/t/contact-form-with-userid-input-instead-of-email-please-help/182189 "2006-03-16T03:41:23Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![lolomedia](https://avatars.discourse-cdn.com/v4/letter/l/ebca7d/32.png) [@lolomedia](https://forum.kirupa.com/u/lolomedia)\
**Post date:** [March 16, 2006, 3:41am UTC](https://forum.kirupa.com/t/contact-form-with-userid-input-instead-of-email-please-help/182189/1 "2006-03-16T03:41:23Z")

</div>

ok so i have my contact form that it grabs user id and message comments  
send it to php and i’ll get on my email.

i don’t know what seems to be the problem… but i have try it in different ways.

this is what i have on my .as submit button

```auto

on (release) {
	
	if (!UserID.length) {
		EmailStatus = "Please enter a valid Progress Energy Corporate ID";
	}   

	else if (!ToComments.length) {
		EmailStatus = "Please enter your message";
	} 
	
	else {
		loadVariablesNum ("MailPHP.php", "0", "Post");
        gotoAndPlay(10);
	}
}

```

and my php says this

```php

<?
$UserID .= "@lolomedia.com";

$ToEmail = "info@lolomedia.com";

$ToSubject = "Training Orientation Feedback";

$EmailBody = "UserID:".UserID."

Message Sent:
".$ToComments."
";

mail($ToName." <".$ToEmail.">",$ToSubject, $EmailBody, "From: ".$UserID." <".$UserID.">");

?>

```

the reason i have it like that is because i want the user to only enter its userid on the form, example  
if my email is [lolo@lolomedia.com](mailto:lolo@lolomedia.com)  
then on this form i will only enter **[COLOR=“Blue”]lolo[/COLOR]**  
because the rest which is @lolomedia.com will be pick up on the php form.

here are my source files…  
[http://www.i-mambo.net/EAS/Mail2.fla](http://www.i-mambo.net/EAS/Mail2.fla)  
[http://www.i-mambo.net/EAS/MailPHP.php](http://www.i-mambo.net/EAS/MailPHP.php)  
[http://www.i-mambo.net/EAS/Mail2.swf](http://www.i-mambo.net/EAS/Mail2.swf) this is the swf.  
please help with this!!
