Home -> Tell a Friend"; $Title = "Best-Custom-Tuxedos-Refer A Friend"; $MetaKeywords = "Refer a Friend, Earn Discounts, Earn Great Discounts."; $MetaDesc = "Refer a Friend and Earn Great Discounts at www.BestCustomTuxedos.com."; include('common/ConnMySQL.php'); if (@$_POST['Name']!="" and @$_POST['Email']!=""){ if (strpos($_POST['Message'],'http:') > 0 and strpos($_POST['Message'],'bestcustom')===false){ header('HTTP/1.1 404 NOT FOUND'); die('Invalid URLs in Message'); } $SQL = "INSERT INTO Tell Set DealerCode=4,Name='".$_POST['Name']."',Email='".$_POST['Email']."',Message='".$_POST['Message']."' ON DUPLICATE KEY UPDATE Name='".$_POST['Name']."',Message='".$_POST['Message']."'"; $a = mysqli_query($Conn,$SQL); if (!$a) die($SQL."

".mysqli_error($Conn)); $TellID = mysqli_insert_id($Conn); for ($Ii=1;$Ii<=10;$Ii++){ if (@$_POST['Name'.$Ii]!="" and @$_POST['Email'.$Ii]!=""){ $a = mysqli_query($Conn,"INSERT IGNORE INTO Referred SET TellID=".$TellID.",Name='".$_POST['Name'.$Ii]."',Email='".$_POST['Email'.$Ii]."'"); if (!$a) die(mysqli_error($Conn)); } } header('Location: ThankYou.php?Msg='.urlencode('Thank you for referring your friends to us.')); exit(); } $Scripts = "function validat(){ if (document.frm.Name.value==''){ alert('Please write your name'); document.frm.Name.focus(); return false; } else if (verifyemail(document.frm.Email.value)==false){ alert('Your email address does not appears to be valid. Please write your correct email address'); document.frm.Email.focus(); return false; } var emp = false; for (I=1;I <= 10; I++){ if (eval('document.frm.Name'+I+'.value')!='' && eval('document.frm.Email'+I+'.value')!=''){ if (verifyemail(eval('document.frm.Email'+I+'.value'))==false){ alert('Email '+I+' do not appear to be correct. Please write correct email address'); eval('document.frm.Email'+I+'.focus();'); return false; break; } emp = true; } } if (emp==false){ alert('Please write Name and Email address of one or more persons to refer.'); return false; } return emp; } "; $Scripts.= 'function verifyemail(email) { if (email=="" || email.indexOf("@")==-1 || email.indexOf(".")==-1){ return false; } email = email.toLowerCase(); NotAllowed = Array("..",".@","@.","@@"," ",";" , ","); Allowed = Array("_","-","0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z",".","@"); for (Ji=0;Ji< NotAllowed.length;Ji++){ if (email.indexOf(NotAllowed[Ji])!=-1){ // Finds a character which is not allowed return false; break; } } // --- Check . or @ is present either at the start or at the end if (email.substr(0,1)=="." || email.substr(0,1)=="@" || email.lastIndexOf(".")==(email.length-1) || email.lastIndexOf("@")==(email.length-1)){ return false; } TT = email.substring(email.indexOf("@")+1); if (TT.indexOf(".")==-1){ // Check . is not present after @ return false; } if (TT.indexOf("@")!=-1){ // there are more than 1 @s in the email return false; } //-------------- Verify Allowed Characters -------------- var found=false; for (Ji=0;Ji< email.length;Ji++){ found = false; for (Ki=0;Ki< Allowed.length;Ki++){ if (email.substr(Ji,1)==Allowed[Ki]){ found=true; break; } } if (found==false){ return false; } } //--------- If All tests above are OK then return true return true; } '; include('top.php'); ?>


 Referral Program

If you are happy with our products and service, please pass the word to your friends, family and colleagues and earn points to receive free merchandise.

We would like to add your friends and family to our e-mail list to receive valuable online coupons, style advice and information on new products as they arrive.

You can check or redeem your points 24/7 on our website and apply them towards your next purchase.

The point system works as follows:

You'll receive 25 points for each referral who makes a purchase from us. Each point earned is worth $1.00.

 Please enter your information in the boxes below.
  Your Name:
  Your Email Address:
 Please enter the names and email addresses of your friends.

Friend's Name

Friend's Email Address


Add a message or comment to our introductory e-mail