# PHP ASP Advanced email form HELP PLEASE!

**URL:** <https://forum.kirupa.com/t/php-asp-advanced-email-form-help-please/214858>\
**Category:** flash\
**Created:** [February 1, 2007, 3:48pm UTC](https://forum.kirupa.com/t/php-asp-advanced-email-form-help-please/214858 "2007-02-01T15:48:16Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jeremy78](https://avatars.discourse-cdn.com/v4/letter/j/6de8d8/32.png) [@Jeremy78](https://forum.kirupa.com/u/Jeremy78)\
**Post date:** [February 1, 2007, 3:48pm UTC](https://forum.kirupa.com/t/php-asp-advanced-email-form-help-please/214858/1 "2007-02-01T15:48:16Z")

</div>

I am getting pretty aggitated! I’ve posted this on every forum I can think of this week codewalkers, kirupa, flashaction, sephiroth etc one would think with all the guru’s out there SOMEONE would respond!! PLEASE Im getting desparate!

I bought a template and it has an advanced email contact form both .ASP and PHP I dont care which one I use if someone could kindly help me. I’ve searched everything I could find on email forms and none of them help me with this form. I did find something on [codewalkers.com](http://codewalkers.com) but the only thing said about it was a portion of the script opening yourself up to spammers… I REALLY DONT CARE! I just want this working! Please Help!

The btn on the email form has this script [INDENT]Code:  
on (rollOver) { this.gotoAndPlay(“s1”);}on (releaseOutside, rollOut) { this.gotoAndPlay(“s2”);}on (release) { var your\_name\_descr = \_parent.your\_name\_descr; var your\_email\_descr = \_parent.your\_email\_descr; var field\_1\_descr = \_parent.field\_1\_descr; var field\_2\_descr = \_parent.field\_2\_descr; var field\_3\_descr = \_parent.field\_3\_descr; var field\_4\_descr = \_parent.field\_4\_descr; var field\_5\_descr = \_parent.field\_5\_descr; var field\_6\_descr = \_parent.field\_6\_descr; var field\_7\_descr = \_parent.field\_7\_descr; var message\_descr = \_parent.message\_descr; var message = \_parent.message; var field\_1 = \_parent.field\_1; var field\_2 = \_parent.field\_2; var field\_3 = \_parent.field\_3; var field\_4 = \_parent.field\_4; var field\_5 = \_parent.field\_5; var field\_6 = \_parent.field\_6; var field\_7 = \_parent.field\_7; var your\_email = \_parent.your\_email; var your\_name = \_parent.your\_name; getURL(“contact.”+\_parent.serv.text, “_blank", “POST”); i = 1; while (this["field_”+i]) { _parent["field_"+i] = “”; i++; } \_parent.reset\_txt(“t1”, “your\_name”, “Your Name:”); \_parent.reset\_txt(“t2”, “your\_email”, “Your Company:”); \_parent.reset\_txt(“t4”, “message”, “Message:”);}  
[/INDENT]The PHP file has this and I have NOT a clue what to edit!  
[INDENT]PHP Code:  
[LEFT][COLOR=#000000][COLOR=#0000bb]\<?  
Print\_r [/COLOR]COLOR=#007700;  
[/COLOR][COLOR=#0000bb]Error\_Reporting[/COLOR][COLOR=#007700]([/COLOR][COLOR=#0000bb]E\_ALL [/COLOR][COLOR=#007700]& ~[/COLOR][COLOR=#0000bb]E\_NOTICE[/COLOR][COLOR=#007700]);  
[/COLOR][COLOR=#0000bb]$subject[/COLOR][COLOR=#007700]=[/COLOR][COLOR=#dd0000]“from”[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]$\_REQUEST[/COLOR][COLOR=#007700][[/COLOR][COLOR=#dd0000]‘Your\_Name’[/COLOR][COLOR=#007700]];  
[/COLOR][COLOR=#0000bb]$headers[/COLOR][COLOR=#007700]= [/COLOR][COLOR=#dd0000]“From:”[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]$\_REQUEST[/COLOR][COLOR=#007700][[/COLOR][COLOR=#dd0000]‘Your\_Email’[/COLOR][COLOR=#007700]].[/COLOR][COLOR=#dd0000]"  
“[/COLOR][COLOR=#007700];  
[/COLOR][COLOR=#0000bb]$headers[/COLOR][COLOR=#007700].=[/COLOR][COLOR=#dd0000]‘Content-type: text/html; charset=iso-8859-1’[/COLOR][COLOR=#007700];  
[/COLOR][COLOR=#0000bb]$i[/COLOR][COLOR=#007700]=[/COLOR][COLOR=#0000bb]1[/COLOR][COLOR=#007700];  
[/COLOR][COLOR=#0000bb]$message[/COLOR][COLOR=#007700]=[/COLOR][COLOR=#dd0000]’’[/COLOR][COLOR=#007700];  
while ([/COLOR][COLOR=#0000bb]$_REQUEST[/COLOR][COLOR=#007700][[/COLOR][COLOR=#dd0000]'field_’[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]$i[/COLOR][COLOR=#007700].[/COLOR][COLOR=#dd0000]’\_descr’[/COLOR][COLOR=#007700]]) {  
[/COLOR][COLOR=#0000bb]$message[/COLOR][COLOR=#007700].=[/COLOR][COLOR=#dd0000]”\<strong\>"[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]$_REQUEST[/COLOR][COLOR=#007700][[/COLOR][COLOR=#dd0000]'field_’[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]$i[/COLOR][COLOR=#007700].[/COLOR][COLOR=#dd0000]’\_descr’[/COLOR][COLOR=#007700]].[/COLOR][COLOR=#dd0000]"\</strong\>&nbsp;&nbsp;&nbsp;“[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]$_REQUEST[/COLOR][COLOR=#007700][[/COLOR][COLOR=#dd0000]'field_’[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]$i[/COLOR][COLOR=#007700]].[/COLOR][COLOR=#dd0000]”\<br\>"[/COLOR][COLOR=#007700];  
[/COLOR][COLOR=#0000bb]$i[/COLOR][COLOR=#007700]++;  
}  
[/COLOR][COLOR=#0000bb]$message[/COLOR][COLOR=#007700].=[/COLOR][COLOR=#dd0000]"\<br\>"[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]$\_REQUEST[/COLOR][COLOR=#007700][[/COLOR][COLOR=#dd0000]‘message’[/COLOR][COLOR=#007700]].[/COLOR][COLOR=#dd0000]"\<br\>\<br\>"[/COLOR][COLOR=#007700];  
[/COLOR][COLOR=#0000bb]mail[/COLOR][COLOR=#007700]([/COLOR][COLOR=#0000bb]$\_REQUEST[/COLOR][COLOR=#007700][[/COLOR][COLOR=#dd0000]‘recipient’[/COLOR][COLOR=#007700]], [/COLOR][COLOR=#0000bb]$subject[/COLOR][COLOR=#007700], [/COLOR][COLOR=#dd0000]"  
\<html\>  
\<head\>  
\<title\>Contact letter\</title\>  
\</head\>  
\<body\>  
\<br\>  
“[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]$message[/COLOR][COLOR=#007700].[/COLOR][COLOR=#dd0000]”  
\</body\>  
\</html\>" [/COLOR][COLOR=#007700], [/COLOR][COLOR=#0000bb]$headers[/COLOR][COLOR=#007700]);  
echo ([/COLOR][COLOR=#dd0000]“Your message was successfully sent!”[/COLOR][COLOR=#007700]);

[/COLOR][COLOR=#0000bb]?\>  
[/COLOR]\<script\>  
resizeTo(300, 300);  
// window.close()  
\</script\>[/COLOR] [/LEFT]

[/INDENT]The .ASP active server form has this code and I haven’t a clue what to edit  
[INDENT]PHP Code:  
[LEFT][COLOR=#000000][COLOR=#0000bb][/COLOR][COLOR=#007700]\<%  
for [/COLOR][COLOR=#0000bb]i[/COLOR][COLOR=#007700]=[/COLOR][COLOR=#0000bb]1 to 7  
message[/COLOR][COLOR=#007700]=[/COLOR][COLOR=#0000bb]message [/COLOR][COLOR=#007700]+ [/COLOR][COLOR=#dd0000]"\<strong\>"[/COLOR][COLOR=#007700]&[/COLOR][COLOR=#0000bb]Request[/COLOR]COLOR=#007700&[/COLOR][COLOR=#dd0000]"\</strong\>&nbsp;&nbsp;&nbsp;“[/COLOR][COLOR=#007700]&[/COLOR][COLOR=#0000bb]Request[/COLOR]COLOR=#007700&[/COLOR][COLOR=#dd0000]”\<br\>"  
[/COLOR][COLOR=#0000bb]next  
message[/COLOR][COLOR=#007700]=[/COLOR][COLOR=#0000bb]message [/COLOR][COLOR=#007700]+ [/COLOR][COLOR=#0000bb]Request[/COLOR]COLOR=#007700  
[/COLOR][COLOR=#0000bb]smtpServer [/COLOR][COLOR=#007700]= [/COLOR][COLOR=#dd0000]“your\_smtp\_server”  
[/COLOR][COLOR=#0000bb]smtpPort [/COLOR][COLOR=#007700]= [/COLOR][COLOR=#0000bb]25

name [/COLOR][COLOR=#007700]= [/COLOR][COLOR=#0000bb]Request[/COLOR]COLOR=#007700  
[/COLOR][COLOR=#0000bb]Set myMail [/COLOR][COLOR=#007700]= [/COLOR][COLOR=#0000bb]CreateObject[/COLOR]COLOR=#007700  
[/COLOR][COLOR=#0000bb]myMail[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]Subject [/COLOR][COLOR=#007700]= [/COLOR][COLOR=#dd0000]“from " [/COLOR][COLOR=#007700]& [/COLOR][COLOR=#0000bb]name  
myMail[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]From [/COLOR][COLOR=#007700]= [/COLOR][COLOR=#0000bb]Request[/COLOR]COLOR=#007700  
[/COLOR][COLOR=#0000bb]myMail[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]To [/COLOR][COLOR=#007700]= [/COLOR][COLOR=#0000bb]Request[/COLOR]COLOR=#007700  
[/COLOR][COLOR=#0000bb]myMail[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]HTMLBody [/COLOR][COLOR=#007700]= [/COLOR][COLOR=#dd0000]”\<html\>\<head\>\<title\>Contact letter\</title\>\</head\>\<body\>\<br\>" [/COLOR][COLOR=#007700]& [/COLOR][COLOR=#0000bb]message [/COLOR][COLOR=#007700]& [/COLOR][COLOR=#dd0000]"\</body\>\</html\>"  
[/COLOR][COLOR=#0000bb]myMail[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]Configuration[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]Fields[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]Item[/COLOR]COLOR=#007700 = [/COLOR][COLOR=#0000bb]2  
myMail[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]Configuration[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]Fields[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]Item[/COLOR]COLOR=#007700 = [/COLOR][COLOR=#0000bb]smtpServer  
myMail[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]Configuration[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]Fields[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]Item[/COLOR]COLOR=#007700 = [/COLOR][COLOR=#0000bb]smtpPort  
myMail[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]Configuration[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]Fields[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]Update  
myMail[/COLOR][COLOR=#007700].[/COLOR][COLOR=#0000bb]Send

[/COLOR][COLOR=#007700]%\>  
[/COLOR][COLOR=#0000bb][/COLOR][/COLOR][/LEFT]

[/INDENT]Now either way this goes, I know what my smtp server is, I just wont edit it until I know exactly what I’m dealing with. At the moment, when I test the email form in the movie, it throws up a download for the PHP form thats in the folder.

I might add this is obviously an advanced email set up, I haven’t seen anything exactly like this on the web as far as I know its an unforgivable sin to sell this and I dont know enough about email forms to break apart a common one let alone an original form. I would REALLY appreciate someone helping me out!!! :hr:
