| | |
php form mail inside the flash
Please support our PHP advertiser: PostgreSQL or MySQL? Compare and contrast the two most popular open source databases
![]() |
•
•
Join Date: Oct 2008
Posts: 14
Reputation:
Solved Threads: 0
hi im trying to make a flash web page. im using a free template for starting. it has a contact form but when i try to use it just not working. where am i making mistake can any1 tell me?i dont know as well so just c/p what i saw in file 
my php file
frame 1
and send frame

my php file
PHP Syntax (Toggle Plain Text)
<?php include("protect.php"); $contact_name = $_POST['name']; $contact_email = $_POST['email']; $contact_subject = $_POST['subject']; $contact_message = $_POST['message']; if( $contact_name == true ) { $sender = $contact_email; $receiver = "xxxxxx@gmail.com"; $client_ip = $_SERVER['REMOTE_ADDR']; $email_body = "Name: $contact_name \nEmail: $sender \nSubject: $contact_subject \nMessage: $contact_message \nIP: $client_ip \nFlash Contact Form provided by http://www.flashmo.com"; $extra = "From: $sender\r\n" . "Reply-To: $sender \r\n" . "X-Mailer: PHP/" . phpversion(); if( mail( $receiver, "Flash Contact Form - $contact_subject", $email_body, $extra ) ) { echo "success=yes"; } else { echo "success=no"; } } ?>
frame 1
PHP Syntax (Toggle Plain Text)
send_button.onRelease = submit; reset_button.onRelease = reset; function submit() { if( contact_name.text == "" || contact_email.text == "" || contact_subject.text == "" || contact_message.text == "" ) { message_status.text = "Lütfen tüm alanları doldurun."; } else if( contact_email.text.indexOf('@') < 2 || contact_email.text.indexOf('.') < 0 ) { message_status.text = "Lütfen geçerli bir e-mail adresi girin."; } else { message_status.text = ""; gotoAndStop("send"); } } function reset() { contact_name.text = contact_email.text = contact_subject.text = contact_message.text = message_status.text = ""; clearInterval(interval_id); gotoAndStop("stop"); }
and send frame
PHP Syntax (Toggle Plain Text)
stop(); loadVariables("send_email.php?flashmo=" + random(1000), this, "POST"); message_status.text = "yollaniyor..."; var i = 0; function check_status() { if( success == "yes" ) { message_status.text = "Mesajınız yollandı!"; play(); } else if( success == "no" ) { message_status.text = "Mesajınız yollanamadı lütfen tekrar deneyin."; gotoAndStop("stop");; } if( i >= 20 ) clearInterval(interval_id); i++; } var interval_id = setInterval(check_status, 400);
![]() |
Other Threads in the PHP Forum
- Previous Thread: display image next to radio button list problem
- Next Thread: (Back) link checker
| Thread Tools | Search this Thread |
advanced ajax apache api array basics beginner binary broken cakephp check checkbox class cms code combobox cookies cron curl database date datepart display dynamic echo email error file files folder form forms function functions google head href htaccess html image include includingmysecondfileinthechain insert integration ip java javascript job joomla js limit link login loop mail menu mlm multiple mysql oop parse password paypal pdf php problem procedure query radio random recursion regex remote script search server sessions smarty smash sms soap source space sql stored syntax system table traffic tutorial unicode update upload url validator variable video web xml youtube





