Send a Text Message
Send Message to Eric’s Cell Phone (it’s free-try it!):
< ?php
################################################################
# Mail-it Now! Upload2Server 1.5.1Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â #
# Script written by: Matthieu Biscay                          #
# Web: http://www.skyminds.net/source/Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â #
# Contact: http://www.skyminds.net/contact/Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â #
# Copyright SkyMinds.Net. All rights reserved.                #
# This script is linkware. Please leave this header here.     #
# For commercial use or custom version contact us.            #
################################################################
// ---------------------------------- EDIT HERE --------------------------------- //
/* Your email where the results of the contact form will be sent to. */
$dest = "7078120376@tmomail.net";
/* The full path to your upload directory. This will appear in the email you'll get so that you can retrieve the uploaded files easily. */
$up_full = "";
/* The relative path to your upload directory from this script. This is an important settings : if the files are not uploaded, chances are that this is not set properly.
Configuration example : if this file is at www.domain.net/contact.php and your upload directory is www.domain.net/upload/, the setting should be :
$up_dir = "./upload/";
*/
$up_dir = "./upload/";
/*Â The number of upload fields you want on the form. Put 0 if you don't want any. */
$UploadNum = "0";
/*Host mail functions. Possible values are 0 or 1. See below:
0 is for most hosts (default value).
1 is for Online.Net (Online). */
$online_isp = "0";
// --------------------------------------------------------------------------------- //
if(isset($_POST["submit"]))
{
// ------------------------ Fields Verification Process ------------------------- //
$Nada = '';
$From = 'blog@ep.com';
$Msg = $_POST['Msg'];
$Name = $_POST['From'];
if(empty($From))
{
$Nada.="Email field is empty !
";
}
if(empty($Msg))
{
$Nada.="Message field is empty !
";
}
$noway = "$Nada" ;
if(empty($Nada) &&
eregi("^[a-z0-9]+([_.-][a-z0-9]+)*@([a-z0-9]+([.-][a-z0-9]+)*)+\\.[a-z]{2,4}$",$From))
{
$ok = TRUE;
}
elseif(!empty($Nada) &&
eregi("^[a-z0-9]+([_.-][a-z0-9]+)*@([a-z0-9]+([.-][a-z0-9]+)*)+\\.[a-z]{2,4}$",$From))
{
$ok = FALSE;
}
else
{
$ml = "Your email address is invalid !
";
$ok = FALSE;
}
// ------------------------------------------------------------------------- //
// ----------------------------- Upload Files ------------------------------ //
$status   = '';
$new_name = '';
$uploaded = '';
$get_files = '';
$all_names = '';
for($i=0;$i
{
$name=$_FILES["fileup"]["name"][$i];
$temp=$_FILES["fileup"]["tmp_name"][$i];
$size=$_FILES["fileup"]["size"][$i];
$type=$_FILES["fileup"]["type"][$i];
if($size > 0)
{
global $up_dir, $all_names;
$length   = 16;
$key_chars = ‘abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789’;
$rand_max = strlen($key_chars) – 1;
for ($i = 0; $i < $length; $i++)
{
$rand_pos = rand(0, $rand_max);
$rand_key[] = $key_chars{$rand_pos};
}
$rand_pass = implode('', $rand_key);
$boom = strlen($Msg) * strlen($From);
$timer = time()* rand(0, $boom);
$timer = $timer . '-' . $rand_pass;
$new_name = $timer . "-" . $name;
$new_name = str_replace(" ","_",$new_name);
@move_uploaded_file($temp, $up_dir . $new_name);
$all_names.= "$new_name\n";
}
}
// ------------------------------------------------------------------------- //
// ----------------------------- Upload Messages --------------------------- //
if(empty($all_names))
{
$status  = "No files uploaded.";
$uploaded = "No files sent.";
}
else
{
$status   = "File(s) successfully uploaded.";
$uploaded = "Yes !\nFiles:";
$get_files = "\nGet the file(s): $up_full";
}
//--------------------------------------------------------------------------- //
// ----------------------------- Mail Builder ------------------------------ //
if($ok == "TRUE")
{
$referer = $_SERVER["HTTP_REFERER"];
$subject = "ep.com";
$body.="\n";
if(count($_POST))
{
while(list($key, $val) = each($_POST))
{
$body.="$key : $val\n";
}
}
$body.="\n";
$body.="$all_names\n";
$body.="$get_files\n";
if($online_isp == "1")
{
if(!email("feedback",$dest,$sujet,$body))
{
print "An error occured during mail delivery
";
}
}
else
{
$header = '';
$header.= 'From: "' . $Name . '" <' . $From . ">\r\n”;
$header.= ‘Reply-To: “‘ . $Name . ‘” < ' . $From . ">\r\n”;
$header.= “X-Mailer: PHP/” . phpversion();
if(!mail($dest, $subject, $body, $header ))
{
print “An error occured during mail delivery
“;
}
}
// ————————————————————————- //
// —————————- Success Message —————————- //
?>
< ?php
}
// ------------------------------------------------------------------------- //
else
{
// ----------------------------- Error Message ----------------------------- //
?>
|
|
||
< ?php // ------------------------------------------------------------------------- // } } else { $num = 0; $upload_box = ''; while($num < $UploadNum) { $num++; $upload_box.= " Â Â File $num:
| –>
Message: |