2016-03-20 3 views
0

Ich versuche, E-Mails, die in mehr als einem Feld für Unternehmen/Kunden aufgeführt sind, die in meinen Datenbanktabellen registriert sind, zu überprüfen, wenn ich mich mit den registrierten Firmen-/Kunden-E-Mails auf meiner Website registriere. Ich habe derzeit eine Tabelle für Unternehmen (tbl_companies) und eine Tabelle für Kunden (tbl_clients), wo ich die E-Mails für beide, die in den Feldern email, email1 und email2 aufgeführt sind, über mein Admin-Panel speichern. Sobald die aufgelisteten E-Mails in einer der Tabellen gespeichert sind, registriert das Unternehmen/die Kunden die für sie aufgeführten E-Mails über ein Firmenanmeldungsformular, das ihnen eine E-Mail mit einem Überprüfungslink sendet, um den Zugriff auf ihr Firmen-/Client-Admin-Panel zu überprüfen ihre Profile.Wie validieren Sie E-Mails, die für Firmen/Kunden aufgeführt sind, die in mehreren Feldern gespeichert sind?

Das Problem, das ich habe, ist zur Zeit nach all E-Mail für die Unternehmen/Kunden in beide der Tabellen, die company_signup Form sieht nur die E-Mails, die für tbl_companies in dem E-Mail-Feld sind (E-Mail) und tbl_clients (E-Mail) . Ich möchte, dass das Feld email, email1 und email2 von tbl_companies und tbl_clients angezeigt wird, wenn das Firmenanmeldungsformular nach der E-Mail sucht, die für die Registrierung und Verifizierung validiert wird.

Bisher habe ich SELECT *, UNION, JOIN und WHERE für SQL-Funktionen versucht, die tbl_companies und tbl_clients zusammenzufassen, indem sie mehr als ein Feld in den beiden Tabellen aufrufen, um sie überprüfen zu lassen.

Ich habe die Funktionen in einer class.php aufgerufen, die sowohl in der company_form.php, client_form.php meines Admin-Panels und company_signup.php meines Anmeldeformulars enthalten ist.

Dies ist der Code von meiner Class.php Seite

\t \t public function get_email_artist($email){ 
 
\t \t 
 
\t \t \t $this->sql = "SELECT * FROM tbl_music_artists WHERE email ='{$email}' 
 
OR email1 ='{$email}' 
 
OR email2 ='{$email}'"; 
 
\t \t \t 
 
\t \t \t $this->data = $this->fetch_row_assoc($this->sql); 
 
\t \t \t if(!empty($this->data)) 
 
\t \t \t \t return $this->data; 
 
\t \t \t else{ 
 
\t \t \t \t return false; 
 
\t \t \t } \t \t 
 
\t \t } 
 

 
\t \t public function get_email_company($email){ 
 
\t \t 
 
\t \t \t $this->sql = "SELECT * FROM tbl_music_companies WHERE email ='{$email}' 
 
OR email1 ='{$email}' 
 
OR email2 ='{$email}'"; 
 
\t \t \t 
 
\t \t \t $this->data = $this->fetch_row_assoc($this->sql); 
 
\t \t \t if(!empty($this->data)) 
 
\t \t \t \t return $this->data; 
 
\t \t \t else{ 
 
\t \t \t \t return false; 
 
\t \t \t } \t \t 
 
\t \t } 
 

 
\t \t public function get_company_email($email){ 
 
\t \t 
 
\t \t \t $this->sql = "SELECT * FROM login WHERE email ='{$email}'"; 
 
\t \t \t 
 
\t \t \t $this->data = $this->fetch_row_assoc($this->sql); 
 
\t \t \t print_r($this->data);exit; 
 
\t \t \t if(!empty($this->data)){ 
 
\t \t \t \t return $this->data; 
 
\t \t \t } 
 
\t \t \t else{ 
 
\t \t \t \t $sql = "(SELECT email, email1, email2 FROM tbl_music_artists WHERE email ='{$email}' 
 
OR email1 ='{$email}' 
 
OR email2 ='{$email}') 
 
\t \t \t \t \t \t UNION 
 
\t \t \t \t \t \t (SELECT email, email1, email2 FROM tbl_music_companies WHERE email ='{$email}' 
 
OR email1 ='{$email}' 
 
OR email2 ='{$email}') 
 
\t \t \t \t \t \t "; 
 
\t \t \t \t $data = $this->fetch_row_assoc($sql); 
 
\t \t \t \t if(!empty($data)){ 
 
\t \t \t \t \t return false; 
 
\t \t \t \t } 
 
\t \t \t \t return true; 
 
\t \t \t } \t \t 
 
\t \t }

\t \t public function register_company($inputs) 
 
\t \t { 
 
\t \t \t if(is_array($inputs)){ 
 
\t \t \t \t // $pwdHasher = new PasswordHash(8, FALSE); 
 
\t \t \t \t // $hash is what you would store in your database 
 
\t \t \t \t // $hash = $pwdHasher->HashPassword($_POST['com_password']); 
 
\t \t \t \t $hash = base64_encode($_POST['com_password']); 
 

 
\t \t \t \t $uname = preg_replace('/@.*?$/', '', $_POST['com_email']); 
 
\t \t \t \t $uname .= rand(); 
 
\t \t \t \t $input_array = array(
 
\t \t \t \t \t 'email' \t \t => trim($_POST['com_email']), 
 
\t \t \t \t \t 'u_type' \t \t => 'company', 
 
\t \t \t \t \t 'password' \t \t => $hash, 
 
\t \t \t \t \t 'username' \t \t => $uname, 
 
\t \t \t \t \t 'name ' \t \t \t => ucwords($_POST['com_name']), 
 
\t \t \t \t \t 'phone' \t \t => $_POST['com_phone'], 
 
\t \t \t \t \t 'city ' \t \t \t => $_POST['com_city'], 
 
\t \t \t \t \t 'country' \t \t => $_POST['com_country'], 
 
\t \t \t \t \t 'website' \t \t => $_POST['com_url'], 
 
\t \t \t \t \t 'gender' \t \t => $_POST['com_gender'], 
 
\t \t \t \t \t 'security_question' \t => $_POST['com_quest'], 
 
\t \t \t \t \t 'security_answer' \t \t => $_POST['com_ans'], 
 
\t \t \t \t \t 'status' \t \t => 0, 
 
\t \t \t \t); 
 
\t \t \t \t 
 
\t \t \t \t $data = $this->get_email_artist(trim($_POST['com_email'])); 
 
\t \t \t \t if($data) { 
 
\t \t \t \t \t \t $this->sendRegisterEmailCompany(array($data[email],$data[email1],$data[email2]), ucwords($_POST['com_name'])); 
 
\t \t \t \t \t \t return $this->insert($input_array, 'login'); 
 
\t \t \t \t } 
 
\t \t \t \t else { 
 
\t \t \t \t \t $data = $this->get_email_company(trim($_POST['com_email'])); 
 
\t \t \t \t \t if($data) { 
 
\t \t \t \t \t \t $this->sendRegisterEmailCompany(array($data[email],$data[email1],$data[email2]), ucwords($_POST['com_name'])); 
 
\t \t \t \t \t \t return $this->insert($input_array, 'login'); \t 
 
\t \t \t \t \t } 
 
\t \t \t \t \t else{ 
 
\t \t \t \t \t \t return 'invalid input'; \t \t \t \t \t \t 
 
\t \t \t \t \t } \t \t \t \t 
 
\t \t \t \t } 
 
\t \t \t } 
 
\t \t \t else{ 
 
\t \t \t \t return 'invalid input'; 
 
\t \t \t } 
 
\t \t } 
 

 
\t \t public function sendRegisterEmailCompany($email, $name) 
 
\t \t { 
 
\t \t \t // ini_set("SMTP","smtp.vianet.com.np"); 
 
    \t \t \t // ini_set("smtp_port","25"); 
 
\t \t \t $url = 'http://'.$_SERVER['HTTP_HOST'].dirname($_SERVER['PHP_SELF']) . '/company_validate.php?identifier=' . base64_encode($email); 
 
\t \t \t 
 
\t \t \t $message = '<html><body>'; 
 
\t \t \t $message .= '<h1>World Music Listing</h1>'; 
 
\t \t \t $message .= '<table rules="all" style="border-color: #666;" cellpadding="10">'; 
 
\t \t \t $message .= "<tr style='background: #eee;'><td>Dear {$name},<br /> You have signed up successfully in the wml guide directory.<br />Before we can proceed please <strong>confirm</strong> your email address. <a href='$url'>Click here</a> OR copy below url and paste into your browser</td></tr>"; 
 
\t \t \t $message .= "<tr style='background: #eee;'><td>$url</td></tr>"; 
 
\t \t \t $message .= "<tr style='background: #eee;'><td>With Regards, <br />World Music Listing</td></tr>"; 
 
\t \t \t $message .= "</table>"; 
 
\t \t \t $message .= "</body></html>"; 
 

 
\t \t \t $to = $email; 
 

 
\t \t \t $subject = 'Company Sign up successful notification- WML Guide'; 
 

 
\t \t \t $headers = "From: " . $email . "\r\n"; 
 
\t \t \t $headers .= "Reply-To: ". $email . "\r\n"; 
 
\t \t \t $headers .= "MIME-Version: 1.0\r\n"; 
 
\t \t \t $headers .= "Content-Type: text/html; charset=ISO-8859-1\r\n"; 
 

 
\t \t \t mail($to, $subject, $message, $headers); 
 
\t \t }

Dies ist der Code in meinem ajax.php ist

\t \t //////// Do not Edit below ///////// 
 
\t \t try { 
 
\t \t \t $dbo = new PDO('mysql:host='.$host_name.';dbname='.$database, $username, $password); 
 
\t \t \t } catch (PDOException $e) { 
 
\t \t \t print "Error!: " . $e->getMessage() . "<br/>"; 
 
\t \t \t die(); 
 
\t \t } 
 
\t \t // Select all artists (clients) and order by name // 
 
\t \t $sql = "SELECT email, email1, email2 
 
FROM tbl_music_artists 
 
WHERE email ='{$com_email}' OR email1 = '{$com_email}' OR email2 = '{$com_email}' 
 
UNION 
 
SELECT email, email1, email2 
 
FROM tbl_music_companies 
 
WHERE email ='{$com_email}' OR email1 = '{$com_email}' OR email2 = '{$com_email}'"; 
 
\t \t \t \t 
 
\t \t $data = $this->fetch_row_assoc($sql); 
 
\t \t 
 
\t \t if(!empty($data)){ 
 
    \t \t \t $valid = true; 
 
\t \t \t echo json_encode($valid); 
 
\t \t } 
 
    \t \t else{ 
 
\t \t \t echo json_encode($valid); 
 
\t \t } 
 
    \t };

Dies ist der Code für meine company_signup Seite

<div class="tab-content"> 
 
\t \t   <div id="page-heading"> 
 
\t \t \t \t \t <h1>World Music Listing Company Registration</h1> 
 
\t \t \t \t \t <hr /> 
 
\t \t \t \t </div> 
 
\t \t \t \t <div id="tab1" class="tab active"> 
 
\t \t \t \t \t <?php if(isset($_SESSION['error'])) { ?> 
 
\t \t \t \t \t <div class="alert alert-error"><?php echo $_SESSION['error']; unset($_SESSION['error']); ?></div> 
 
\t \t \t \t \t <?php } ?> 
 
\t \t \t \t \t <form class="form-style-1" id="register" method="POST" action="signupcompanycontroller.php"> 
 
\t \t \t \t \t \t <ul class="form-style-1"> 
 
\t \t \t \t \t \t \t <li class="bottom"><label>Account Details</label></li> 
 
\t \t \t \t \t \t  <li> 
 
\t \t \t \t \t \t   <label>Email <span class="required">*</span></label> 
 
\t \t \t \t \t \t   <input type="email" name="com_email" class="field-long" placeholder="enter your email address" size="50" required /> 
 
\t \t \t \t \t \t  </li> 
 
\t \t \t \t \t \t  <li> 
 
\t \t \t \t \t \t  \t <label>Password <span class="required">*</span></label> 
 
\t \t \t \t \t \t \t \t <input type="password" name="com_password" class="field-long" placeholder="enter password" size="50" required id="password" /> 
 
\t \t \t \t \t \t \t </li> 
 
\t \t \t \t \t \t \t <li> 
 
\t \t \t \t \t \t  \t <label>Confirm Password <span class="required">*</span></label> 
 
\t \t \t \t \t \t \t \t <input type="password" name="com_conpassword" class="field-long" placeholder="enter confirm password" size="50" required /> 
 
\t \t \t \t \t \t \t </li> 
 
\t \t \t \t \t \t \t <li class="bottom"><label>Personal Details</label></li> 
 
\t \t \t \t \t \t \t <li> 
 
\t \t \t \t \t \t  \t <label>Full Name <span class="required">*</span></label> 
 
\t \t \t \t \t \t \t \t <input type="text" name="com_name" class="field-long" placeholder="enter your full name" size="50" required /> 
 
\t \t \t \t \t \t \t </li> 
 
\t \t \t \t \t \t \t <li> 
 
\t \t \t \t \t \t  \t <label>Phone <span class="required">*</span></label> 
 
\t \t \t \t \t \t \t \t <input type="text" name="com_phone" class="field-long" placeholder="enter your phone number" size="50" required /> 
 
\t \t \t \t \t \t \t </li> 
 
\t \t \t \t \t \t \t <!-- <li> 
 
\t \t \t \t \t \t  \t <label>Street Address</label> 
 
\t \t \t \t \t \t \t \t <input type="text" name="com_address" class="field-long" placeholder="enter your Street Address" size="50" /> 
 
\t \t \t \t \t \t \t </li> --> 
 
\t \t \t \t \t \t \t <li> 
 
\t \t \t \t \t \t  \t <label>City <span class="required">*</span></label> 
 
\t \t \t \t \t \t \t \t <input type="text" name="com_city" class="field-long" placeholder="enter your city name" size="50" required /> 
 
\t \t \t \t \t \t \t </li> 
 
\t \t \t \t \t \t \t <li> 
 
\t \t \t \t \t \t  \t <label>Country <span class="required">*</span></label> \t \t \t \t \t \t  \t 
 
\t \t \t \t \t \t  \t <select name="com_country" class="field-divided" required> 
 
\t \t \t \t \t \t  \t \t <option value="">Select One</option> 
 
\t \t \t \t \t \t  \t \t <?php 
 
\t \t \t \t \t \t  \t \t \t $country_list = country(); 
 
\t \t \t \t \t \t  \t \t \t foreach ($country_list as $key => $value) { 
 
\t \t \t \t \t \t  \t \t \t \t if(!empty($value)) 
 
\t \t \t \t \t \t  \t \t \t \t \t echo '<option>' . $value . '</option>'; 
 
\t \t \t \t \t \t  \t \t \t } 
 
\t \t \t \t \t \t  \t \t ?> 
 
\t \t \t \t \t \t  \t </select> 
 
\t \t \t \t \t \t \t </li> 
 
\t \t \t \t \t \t \t <li> 
 
\t \t \t \t \t \t  \t <label>Website</label> 
 
\t \t \t \t \t \t \t \t <input type="url" name="com_url" class="field-long" placeholder="enter website url" size="50" /> 
 
\t \t \t \t \t \t \t </li> 
 
\t \t \t \t \t \t \t <li> 
 
\t \t \t \t \t \t  \t <label>Gender</label> 
 
\t \t \t \t \t \t \t \t <select name="com_gender" class="field-divided"> 
 
\t \t \t \t \t \t  \t \t <option value="">Select One</option> 
 
\t \t \t \t \t \t  \t \t <option>Male</option> 
 
\t \t \t \t \t \t  \t \t <option>Female</option> 
 
\t \t \t \t \t \t  \t </select> 
 
\t \t \t \t \t \t \t </li> 
 
\t \t \t \t \t \t \t <li class="bottom"><label>Security</label></li> 
 
\t \t \t \t \t \t \t <li> 
 
\t \t \t \t \t \t  \t <label>Security Question <span class="required">*</span></label> 
 
\t \t \t \t \t \t \t \t <select name="com_quest" class="field-long" required> 
 
\t \t \t \t \t \t  \t \t <option value="">Select One</option> 
 
\t \t \t \t \t \t  \t \t <option value="What is the name of your favorite pet?">What is the name of your favorite pet?</option> 
 
\t \t \t       <option value="What is your preferred musical genre?">What is your preferred musical genre?</option> 
 
\t \t \t       <option value="What is the street number of the house you grew up in">What is the street number of the house you grew up in?</option> 
 
\t \t \t       <option value="What time of the day were you born?">What time of the day were you born?</option> 
 
\t \t \t       <option value="What is the name of your favorite childhood friend?">What is the name of your favorite childhood friend?</option> 
 
\t \t \t       <option value="What is the name of the company of your first job?">What is the name of the company of your first job?</option> 
 
\t \t \t       <option value="What is the middle name of your oldest sibling?">What is the middle name of your oldest sibling?</option> 
 
\t \t \t       <option value="What is the middle name of your oldest child?">What is the middle name of your oldest child?</option> 
 
\t \t \t       <option value="What was the last name of your third grade teacher?">What was the last name of your third grade teacher?</option> 
 
\t \t \t       <option value="What was your childhood nickname?">What was your childhood nickname?</option> 
 
\t \t \t       <option value="What is your spouse’s mother’s maiden name?">What is your spouse’s mother’s maiden name?</option> 
 
\t \t \t       <option value="What is your mother’s maiden name?">What is your mother’s maiden name?</option> 
 
\t \t \t       <option value="What was your high school mascot?">What was your high school mascot?</option> 
 
         \t \t </select> 
 
\t \t \t \t \t \t \t </li> 
 
\t \t \t \t \t \t \t <li> 
 
\t \t \t \t \t \t  \t <label>Answer</label> 
 
\t \t \t \t \t \t \t \t <input type="text" name="com_ans" class="field-long" placeholder="enter your answer" size="50" required /> 
 
\t \t \t \t \t \t \t </li> 
 
\t \t \t \t \t \t \t <li class="bottom"><label>Terms and Mailing</label></li> 
 
\t \t \t \t \t \t \t <li> 
 
\t \t \t \t \t \t \t \t <label class="term"><input type="checkbox" name="com_terms" value="1" required class="condition"> <span class="required">*</span> <span id="terms">I accept the Terms and Conditions</span></label> 
 
\t \t \t \t \t \t \t \t <!-- <label><input type="checkbox" name="com_offer" value="1"> I want to receive personalized offers by your site</label> 
 
\t \t \t \t \t \t \t \t <label><input type="checkbox" name="com_offer_partner" value="1"> Allow partners to send me personalized offers and related services</label> --> 
 

 
\t \t \t \t \t \t \t </li> 
 
\t \t \t \t \t \t \t <li> 
 
\t \t \t \t \t \t \t \t <label>&nbsp;</label> 
 
\t \t \t \t \t \t \t \t <input type="submit" value="Register" id="form_submit" /> 
 
\t \t \t \t \t \t \t </li> 
 
\t \t \t \t \t  </ul> 
 
\t \t \t \t \t </form> 
 
\t \t \t \t </div> 
 
\t \t \t </div> 
 
\t \t </div> 
 
\t </div> 
 
\t <div id="termscondition" style="display: none;" title="Terms and Conditions"> 
 
\t \t A. \t By using or visiting the World Music Listing website or any World Music Listing products, software, data feeds, including but not limited to its music/entertainment directory/list of contacts, and services provided to you on, from, or through the World Music Listing website (collectively the "Service") you signify your agreement to (1) these terms and conditions (the "Terms of Service"), (2) World Music Listing's Privacy Policy, found at http://www.wmlmusicguide.com/terms.php and incorporated herein by reference, and (3) World Music Listing's Community Guidelines, found at http://www.wmlmusicguide.com/terms.php and also incorporated herein by reference. If you do not agree to any of these terms, the World Music Listing Privacy Policy, or the Community Guidelines, please do not use the Service. 
 
\t \t 
 
\t \t <a href="terms.php" target="_blank">Please read more</a> 
 
\t </div> 
 
<!-- end content-outer......END --> \t 
 
\t <link rel="stylesheet" href="//code.jquery.com/ui/1.11.4/themes/smoothness/jquery-ui.css"> 
 
\t <script src="public/js/jquery.validate.min.js"></script> 
 
\t <script src="//code.jquery.com/ui/1.11.4/jquery-ui.js"></script> \t 
 
\t <script> 
 
\t \t $().ready(function(){ 
 
\t \t \t $('#register').validate({ 
 
\t \t   rules: { 
 
\t \t    com_email: { 
 
\t \t \t \t \t \t required: true, 
 
\t \t \t \t \t \t email: true, 
 
\t \t \t \t \t \t remote: 'ajax_company.php' 
 
\t \t \t \t \t \t }, 
 
\t \t \t \t \t com_password: { 
 
\t \t \t \t \t \t minlength: 6, 
 
\t \t \t \t \t \t required: true 
 
\t \t \t \t \t \t }, 
 
\t \t    com_conpassword: { 
 
\t \t \t \t \t \t equalTo : '#password;' 
 
\t \t \t \t \t \t }, 
 
\t \t    com_name: { 
 
\t \t \t \t \t \t minlength: 3, 
 
\t \t \t \t \t \t required: true 
 
\t \t \t \t \t \t }, 
 
\t \t    com_phone: { 
 
\t \t \t \t \t \t required: true 
 
\t \t \t \t \t \t }, 
 
\t \t    com_city: { 
 
\t \t \t \t \t \t required: true 
 
\t \t \t \t \t \t }, 
 
\t \t    com_country: { 
 
\t \t \t \t \t \t required: true 
 
\t \t \t \t \t \t }, 
 
\t \t    com_quest: { 
 
\t \t \t \t \t \t required: true 
 
\t \t \t \t \t \t }, 
 
\t \t    com_ans: { 
 
\t \t \t \t \t \t required: true 
 
\t \t \t \t \t \t }, 
 
\t \t    com_terms: { 
 
\t \t \t \t \t \t required: true 
 
\t \t \t \t \t } 
 
\t \t   }, 
 
\t \t   messages: { \t \t \t 
 
\t \t \t \t \t com_email: { 
 
\t \t \t \t \t \t remote: 'Entered email address not found.' 
 
\t \t \t \t \t } 
 
\t \t \t \t }, 
 
\t \t \t \t errorElement: 'span', 
 
\t \t \t \t errorPlacement: function (error, element) { 
 
\t \t    if (element.attr('type') == 'checkbox') { 
 
\t \t     error.insertAfter($('.term')); 
 
\t \t    } else { 
 
\t \t     error.insertAfter(element); 
 
\t \t    } 
 
\t \t   } \t \t 
 
\t \t \t }); 
 

 
\t \t \t $('.condition').click(function() { 
 
\t \t   if ($(this).is(':checked')) { 
 
\t \t    $('#termscondition').dialog({ 
 
\t \t    \t modal: true, 
 
\t \t    \t width: 600, 
 
\t \t \t \t \t  buttons: { 
 
\t \t \t \t \t   Ok: function() { 
 
\t \t \t \t \t   \t $(this).dialog('close'); 
 
\t \t \t \t \t  \t } \t \t    
 
\t \t \t \t \t  } 
 
\t \t    }); 
 
\t \t   } else { 
 
\t \t    $('#termscondition').dialog('close'); 
 
\t \t   } 
 
\t \t  }); 
 
\t \t }); 
 
\t </script>

Antwort

0

Das Problem, dass Sie nur zu sein scheint, sind gegen die erste E-Mail-Feld auswählen. Wenn Sie gegen alle E-Mail-Felder überprüfen möchten, müssen Sie aktualisieren Sie Ihre WHERE-Bedingung wie folgt:

$sql = "SELECT email, email1, email2 
FROM tbl_music_artists 
WHERE email ='{$com_email}' OR email1 = '{$com_email}' OR email2 = '{$com_email}' 
UNION 
SELECT email, email1, email2 
FROM tbl_music_companies 
WHERE email ='{$com_email}' OR email1 = '{$com_email}' OR email2 = '{$com_email}' 

EDIT:

Diese Funktion:

$data = $this->get_email_artist(trim($_POST['com_email'])); 

zurückkehren müssen alle E-Mail-Adressen.

Dann muss diese Funktion, um die Adressen aller an E-Mail: es sendet nur an den $ _POST [ 'com_email']

$this->sendRegisterEmailCompany(trim($_POST['com_email']), ucwords($_POST['com_name'])); 

Im Moment. Es hängt von dieser Funktion, aber Sie sollten es die E-Mail-Adressen, dh ein Array hindurchgeführt werden können:

$this->sendRegisterEmailCompany(array($data['email1'],$data['email2'],$data['email3']), ucwords($_POST['com_name'])); 
+0

Abhängig von dieser Funktion (sendRegisterEmailCompany), würden Sie benötigen entweder ein Array mit allen E-Mail-Adressen aus dem passieren Abfrage Ergebnis, oder rufen Sie es einmal für jede E-Mail-Adresse. $ this-> sendRegisterEmailCompany (array ($ data [email1], $ data [EMAIL2]), ucwords ($ _ POST [ 'com_name'])); – jfxninja

+0

Vielen Dank, würde dies der gleiche Grund sein, warum nur die erste E-Mail von den Tbl_music_artists und tbl_music_companies die E-Mail-Benachrichtigung mit dem Bestätigungslink erhält? Ich erhalte das Formular company_signup, um die E-Mails in allen drei Feldern in beiden Tabellen anzuzeigen, aber nur die E-Mail-Adresse, die im ersten E-Mail-Feld von tbl_music_artists aufgeführt ist, erhält die E-Mail. ['com_email'] ist der Name des E-Mail-Felds auf der Seite company_signup.php. –

+0

Ich vermisse etwas, aber die E-Mail mit dem Bestätigungslink wird immer noch nicht an die E-Mail-Adressen gesendet, die in den Feldern email1 und email2 aufgeführt sind. –

Verwandte Themen