Autoplay media studio Email gönderim sistemi bu sistemin çalışabilmesi için bir ftp adresiniz olması gerekmektedir. ve bu ftp adresine mail.php diye bir dosya eklenerek mail sistemi çalıştırılır yukarda örnek bir aps dosyası ekledim.
send it butonu üzerindeki kodlar
PHP:
-- clear error variable
error = 0;
-- Get values from input fields
from = Input.GetText("Input1");
subject = Input.GetText("Input2");
body = Input.GetText("Input3");
-- check for empty fields and deliver errors if needed
if String.Length(from) < 1 then
Dialog.Message("Error", "Please enter your email address and re-submit. Thank you.");
error = 1;
end
if String.Length(subject) < 1 then
Dialog.Message("Error", "Please enter your email subject and re-submit. Thank you.");
error = 1;
end
if String.Length(body) < 1 then
Dialog.Message("Error", "Please enter your email message and re-submit. Thank you.");
error = 1;
end
if error~=1 then
-- if no errors exist, send the email now and give a confirmation dialog
-- Don't forget to change the HTTP.Submit URL parameter to the actual Web site!
HTTP.Submit("http://www.yourwebsite.com/mail.php", {from=from, subject=subject, body=body}, SUBMITWEB_POST, 20, 80, nil, nil);
Dialog.Message("Success", "Success, your info has been submitted.");
Application.Exit();
end
PHP:
<?php
// specify recipient email address
$to="TYPE-YOUR-EMAIL-ADDRESS-HERE";
// send our email
mail ("$to","$subject","$body","$from");
?>
your php mail script
PHP:
<?php
// specify recipient email address
$to="info@realestatemediadesign.com";
// send our email
mail("$to","$from","$subject","$body");
?>
on click
PHP:
-- clear error variable
error = 0;
-- Get values from input fields
from = Input.GetText("Input1");
subject = Input.GetText("Input2");
body = Input.GetText("Input3");
-- check for empty fields and deliver errors if needed
if String.Length(from) < 1 then
Dialog.Message("ERROR", "Bla Bla.");
error = 1;
end
if String.Length(subject) < 1 then
Dialog.Message("ERROR", "Bla Bla.");
error = 1;
end
if String.Length(body) < 1 then
Dialog.Message("ERROR", "Bla Bla.");
error = 1;
end
if error~=1 then
-- if no errors exist, send the email now and give a confirmation dialog
HTTP.Submit("http://www.yourwebsite.com/mail.php", {from=from, subject=subject, body=body}, SUBMITWEB_POST, 20, 80, nil, nil);
Dialog.Message("Thanks", "Bla Bla ");
end
Eklentiler
Son düzenleyen: Moderatör: