request-conversation.php 15.2 KB
<?php 

function send_planner_notice()
{
    $name  = $_REQUEST['name'];
    $email = $_REQUEST['email'];
    $phone = $_REQUEST['phone'];
	$age = $_REQUEST['age'];
	$about = $_REQUEST['about'];
	$contact = $_REQUEST['contact'];
    $panner_id = $_REQUEST['planner_id'];

    if($email =="" ||  $name  =="" ||  $phone  =="" ){
        exit;
    }

    if(strpos($email, 'tenzing') !== false) {
        $to = 'support@gotenzing.com';
    } else {
        $to = get_post_meta($panner_id, 'wpsl_email', true);
    }

    $subject = 'You\'ve got a new client prospect!';
    $headers = array('Content-Type: text/html; charset=UTF-8');
	
  ob_start();?>

<!DOCTYPE html>
<html lang="en" xmlns="http://www.w3.org/1999/xhtml" xmlns:o="urn:schemas-microsoft-com:office:office">
   <head>
      <meta charset="UTF-8">
      <meta name="viewport" content="width=device-width,initial-scale=1">
      <meta name="x-apple-disable-message-reformatting">
      <title></title>
      <!--[if mso]>
      <noscript>
         <xml>
            <o:OfficeDocumentSettings>
               <o:PixelsPerInch>96</o:PixelsPerInch>
            </o:OfficeDocumentSettings>
         </xml>
      </noscript>
      <![endif]-->
      <style>
         @font-face { font-family: Calibri;
         src: url('https://yournumbers.ca/wp-content/themes/understrap-child/Calibri.woff') format('woff'); }
         @font-face { font-family: Calibri-bold;
         src: url('https://yournumbers.ca/wp-content/themes/understrap-child/Calibri-Bold.woff') format('woff'); }
         table, td, div, h1, p {font-family: Calibri;}
         strong{font-family: Calibri;}
		 .f-16 tr td{font-size:24px;line-height:28px;font-family: Calibri;color:#012169; }
		 .f-16 tr td:first-child { width:30%;}
      </style>
   </head>
   <body style="margin:0;padding:0;">
      <table role="presentation" style="width:100%;border-collapse:collapse;border:0;border-spacing:0;background:#ffffff;">
         <tr>
            <td align="center" style="padding:0;">
				<table bgcolor="#005EB8;" role="presentation" style="width:602px;border-collapse:collapse;border-spacing:0;text-align:left;">
                  <tr style="background:#005EB8;">
                     <td align="center">
                        &nbsp;
                     </td>
                     <td align="center">
                        &nbsp;
                     </td>
                     <td align="center" width="135">
						<img width="135" src="https://yournumbers.ca/wp-content/uploads/2022/01/Group-1073@2x.png" class="img-fluid" alt="FP Canada">
					</td>
                     <td align="center" width="40">
                        &nbsp;&nbsp;
                     </td>
                  </tr>
                  <tr style="background:#005EB8;">
                     <td colspan="4" style="padding:36px 30px 42px 30px;">
                        <table role="presentation" style="width:100%;border-collapse:collapse;border:0;border-spacing:0;">
                           <tr>
                              <td style="padding:0 0 36px 0;color:#153643;">
                                 <h1 style="font-size:40px;line-height:45px;color:#fff;margin:0 0 20px 0; font-family: Calibri-bold;">
								 YOU'VE BEEN CONTACTED<br>
								 THROUGH THE WHAT'S YOUR<br>
								 NUMBER CAMPAIGN.
                                 </h1>
                              </td>
                           </tr>
                        </table>
                     </td>
                  </tr>
				  <tr style="background:#ffffff;">
					<td colspan="4" style="padding:36px 30px 42px 30px;">
					   <table role="presentation" style="width:100%;border-collapse:collapse;border:0;border-spacing:0;">
						  <tr>
							 <td colspan="3" style="padding:0 0 36px 0;color:#153643;">
								<p style="margin:0 0 12px 0;font-size:24px;line-height:28px;font-family: Calibri;color:#012169;">Good luck with your new client prospect. Remember to reply to the person who reached out to you within one business day. And keep track of the results - the more we learn, the better we'll do.</p>
							</td>
						  </tr>
						  <tr>
							 <td colspan="3" style="padding:0 0 36px 0;color:#153643;">
								<?php echo "<table class='f-16'><tr><td>NAME:</td><td>" .  $name  . "</td></tr><tr><td>EMAIL:</td><td>" .$email . "</td></tr><tr><td>PHONE:</td><td>" .  $phone . "</td></tr><tr><td>AGE:</td><td>" .$age . "</td></tr><tr><td>CONTACT BY:</td><td>" .  $contact  . "</td></tr><tr><td colspan='2'>TALK ABOUT:<br><br>" .$about . "</td></tr></table>"; ?>
							</td>
						  </tr>
						  <tr style="background:#ffffff;">
							 <td colspan="4" style="padding-bottom:10px">
							 </td>
						  </tr>
						  <tr>
							 <td align="center">
								&nbsp;
							 </td>
							 <td align="center">
							 &nbsp;
							 </td>
							 <td align="center">
								&nbsp;
							 </td>
						  </tr>
					   </table>
					</td>
				 </tr>
				 <tr>
					<td colspan="4" style="padding:30px;background:#fff;">
					   <table role="presentation" style="width:100%;border-collapse:collapse;border:0;border-spacing:0;font-size:9px;font-family:Arial,sans-serif;">
						  <tr>
							 <td style="padding-bottom:50px;width:5%;" align="left">
								&nbsp;&nbsp;
							 </td>
							 <td style="padding:0;width:90%;border-top: 1px solid #000;" align="left">
								<table role="presentation" style="width:100%;border-collapse:collapse;border:0;border-spacing:0;">
								   <tr>
									  <td colspan="6" style="padding:0;width:5%;" align="left">
										 &nbsp;&nbsp;
									  </td>
								   </tr>
								   <tr>
									  <td style="padding:0;width:5%;" align="center">
										&nbsp;&nbsp;
									  </td>
									  <td style="padding:0;width:5%;" align="center">
										<a href="https://twitter.com/OfficialFPCan">
										 <img width="16" src="https://yournumbers.ca/wp-content/uploads/2022/01/t.png" class="img-fluid" alt="FP Canada">
										</a>
									  </td>
									  <td style="padding:0;width:5%;" align="center">
										<a href="https://www.facebook.com/OfficialFPCanada">
										 <img width="8" src="https://yournumbers.ca/wp-content/uploads/2022/01/fb.png" class="img-fluid" alt="FP Canada">
										</a>
									  </td>
									  <td style="padding:0;width:5%;" align="center">
										<a href="https://www.youtube.com/c/FPCanadaOfficial">
										 <img width="16" src="https://yournumbers.ca/wp-content/uploads/2022/01/you.png" class="img-fluid" alt="FP Canada">
										</a>
									  </td>
									  <td style="padding:0;width:5%;" align="center">
										<a href="https://www.linkedin.com/company/fpcanada/">
										 <img width="16" src="https://yournumbers.ca/wp-content/uploads/2022/01/link.png" class="img-fluid" alt="FP Canada">
										</a>
									  </td>
									  <td style="padding:0;width:5%;" align="center">
										 &nbsp;&nbsp;
									  </td>
								   </tr>
								</table>
							 </td>
							 <td style="padding:0;width:5%;" align="left">
							 </td>
						  </tr>
						  <tr>
							 <td style="padding-bottom:0px;width:5%;" align="left">
								&nbsp;&nbsp;
							 </td>
						  </tr>
						  <tr>
							 <td colspan="4" style="padding-bottom:10px;width:5%; font-size:14px;" align="center">
								<p><strong>FP Canada</strong><br>
								   902-375 University Ave.<br>
								   Toronto, ON  M5G 2J5 <br>
								   <a style="color:#5B6770;text-decoration: none;" href="tel:1 800 305 9886">1 800 305 9886</a> |   <a  style="color:#5B6770;text-decoration: none;" href="mailto:wyncampaign@fpcanada.ca">wyncampaign@fpcanada.ca</a>
								</p>
								<p style="color:#5B6770;"><i>Copyright © 2022 FP Canada, All rights reserved.</i></p>

								<p style="color:#5B6770;">CFP®, Certified Financial Planner® and CFP logo are trademarks owned by Financial Planning Standards Board Ltd. (FPSB) and used under license. QAFP™, Qualified Associate Financial Planner, QAFP logo and all other trademarks are owned by FP Canada™. © 2022 FP Canada™. All rights reserved.</p>
							 </td>
						  </tr>
					   </table>
					</td>
				 </tr>
			  </table>
			  </td>
			  </tr>
        </table>
           
   </body>
</html>

<?php   

$body = ob_get_clean();

wp_mail($to, $subject, $body, $headers);

$to_customer = $_REQUEST['email'];
$subject_customer = 'What\'s Your Number Request Confirmation';
$headers_customer = array('Content-Type: text/html; charset=UTF-8');
	
ob_start();?>

<!DOCTYPE html>
<html lang="en" xmlns="http://www.w3.org/1999/xhtml" xmlns:o="urn:schemas-microsoft-com:office:office">
   <head>
      <meta charset="UTF-8">
      <meta name="viewport" content="width=device-width,initial-scale=1">
      <meta name="x-apple-disable-message-reformatting">
      <title></title>
      <!--[if mso]>
      <noscript>
         <xml>
            <o:OfficeDocumentSettings>
               <o:PixelsPerInch>96</o:PixelsPerInch>
            </o:OfficeDocumentSettings>
         </xml>
      </noscript>
      <![endif]-->
      <style>
         @font-face { font-family: Calibri;
         src: url('https://yournumbers.ca/wp-content/themes/understrap-child/Calibri.woff') format('woff'); }
         @font-face { font-family: Calibri-bold;
         src: url('https://yournumbers.ca/wp-content/themes/understrap-child/Calibri-Bold.woff') format('woff'); }
         table, td, div, h1, p {font-family: Calibri;}
         strong{font-family: Calibri;}
      </style>
   </head>
   <body style="margin:0;padding:0;">
      <table role="presentation" style="width:100%;border-collapse:collapse;border:0;border-spacing:0;background:#ffffff;">
         <tr>
            <td align="center" style="padding:0;">
				<table bgcolor="#005EB8;" role="presentation" style="width:602px;border-collapse:collapse;border-spacing:0;text-align:left;">
                  <tr style="background:#005EB8;">
                     <td align="center">
                        &nbsp;
                     </td>
                     <td align="center">
                        &nbsp;
                     </td>
                     <td align="center" width="135">
					 &nbsp;
					</td>
                     <td align="center" width="40">
                        &nbsp;&nbsp;
                     </td>
                  </tr>
                  <tr style="background:#005EB8;">
                     <td colspan="4" style="padding:36px 30px 42px 30px;">
                        <table role="presentation" style="width:100%;border-collapse:collapse;border:0;border-spacing:0;">
                           <tr>
                              <td style="padding:0 0 36px 0;color:#153643;">
                                 <h1 style="font-size:50px;line-height:55px;color:#fff;margin:0 0 20px 0; font-family: Calibri-bold;">
								 LET'S BOOST YOUR FINANCIAL CONFIDENCE TOGETHER.
                                 </h1>
                              </td>
                           </tr>
                        </table>
                     </td>
                  </tr>
				  <tr style="background:#ffffff;">
					<td colspan="4" style="padding:36px 30px 42px 30px;">
					   <table role="presentation" style="width:100%;border-collapse:collapse;border:0;border-spacing:0;">
						  <tr>
							 <td colspan="3" style="padding:0 0 36px 0;color:#153643;">
								<p style="margin:0 0 12px 0;font-size:24px;line-height:28px;font-family: Calibri;color:#012169;">Thank you for requesting a conversation about your most important number and how to ensure the rest add up. You'll receive a reply within one business day and we'll get started.</p>
							</td>
						  </tr>

						  <tr style="background:#ffffff;">
							 <td colspan="4" style="padding-bottom:10px">
							 </td>
						  </tr>
						  <tr>
							 <td align="center">
								&nbsp;
							 </td>
							 <td align="center">
								<img width="147" src="https://yournumbers.ca/wp-content/uploads/2022/01/Group-1028@2x.png" class="img-fluid" alt="FP Canada">
							 </td>
							 <td align="center">
								&nbsp;
							 </td>
						  </tr>
					   </table>
					</td>
				 </tr>
				 <tr>
					<td colspan="4" style="padding:30px;background:#fff;">
					   <table role="presentation" style="width:100%;border-collapse:collapse;border:0;border-spacing:0;font-size:9px;font-family:Arial,sans-serif;">
						  <tr>
							 <td style="padding-bottom:50px;width:5%;" align="left">
								&nbsp;&nbsp;
							 </td>
							 <td style="padding:0;width:90%;border-top: 1px solid #000;" align="left">
								<table role="presentation" style="width:100%;border-collapse:collapse;border:0;border-spacing:0;">
								   <tr>
									  <td colspan="6" style="padding:0;width:5%;" align="left">
										 &nbsp;&nbsp;
									  </td>
								   </tr>
								   <tr>
									  <td style="padding:0;width:5%;" align="center">
										&nbsp;&nbsp;
									  </td>
									  <td style="padding:0;width:5%;" align="center">
										<a href="https://twitter.com/OfficialFPCan">
										 <img width="16" src="https://yournumbers.ca/wp-content/uploads/2022/01/t.png" class="img-fluid" alt="FP Canada">
										</a>
									  </td>
									  <td style="padding:0;width:5%;" align="center">
										<a href="https://www.facebook.com/OfficialFPCanada">
										 <img width="8" src="https://yournumbers.ca/wp-content/uploads/2022/01/fb.png" class="img-fluid" alt="FP Canada">
										</a>
									  </td>
									  <td style="padding:0;width:5%;" align="center">
										<a href="https://www.youtube.com/c/FPCanadaOfficial">
										 <img width="16" src="https://yournumbers.ca/wp-content/uploads/2022/01/you.png" class="img-fluid" alt="FP Canada">
										</a>
									  </td>
									  <td style="padding:0;width:5%;" align="center">
										<a href="https://www.linkedin.com/company/fpcanada/">
										 <img width="16" src="https://yournumbers.ca/wp-content/uploads/2022/01/link.png" class="img-fluid" alt="FP Canada">
										</a>
									  </td>
									  <td style="padding:0;width:5%;" align="center">
										 &nbsp;&nbsp;
									  </td>
								   </tr>
								</table>
							 </td>
							 <td style="padding:0;width:5%;" align="left">
							 </td>
						  </tr>
						  <tr>
							 <td style="padding-bottom:0px;width:5%;" align="left">
								&nbsp;&nbsp;
							 </td>
						  </tr>
						  <tr>
							 <td colspan="4" style="padding-bottom:10px;width:5%; font-size:14px;" align="center">
								<p><strong>FP Canada</strong><br>
								   902-375 University Ave.<br>
								   Toronto, ON  M5G 2J5 <br>
								   <a style="color:#5B6770;text-decoration: none;" href="tel:1 800 305 9886">1 800 305 9886</a> | <a  style="color:#5B6770;text-decoration: none;" href="mailto:wyncampaign@fpcanada.ca">wyncampaign@fpcanada.ca</a>
								</p>
								<p style="color:#5B6770;"><i>Copyright © 2022 FP Canada, All rights reserved.</i></p>

								<p style="color:#5B6770;">CFP®, Certified Financial Planner® and CFP logo are trademarks owned by Financial Planning Standards Board Ltd. (FPSB) and used under license. QAFP™, Qualified Associate Financial Planner, QAFP logo and all other trademarks are owned by FP Canada™. © 2022 FP Canada™. All rights reserved.</p>
							 </td>
						  </tr>
					   </table>
					</td>
				 </tr>
			  </table>
			  </td>
			  </tr>
        </table>
           
   </body>
</html>

<?php   

$body_customer = ob_get_clean();

				  
wp_mail($to_customer, $subject_customer, $body_customer, $headers_customer);
		 }