-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #112 from MathieuNls/58_new_input
New click-based synchronization system #58
- Loading branch information
Showing
14 changed files
with
442 additions
and
413 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -304,17 +304,15 @@ function contact() { | |
|
||
$result['success'] = false; | ||
|
||
$name = $this->input->post('name'); | ||
$email = $this->input->post('email'); | ||
$message = $this->input->post('message'); | ||
$tags = "contact"; | ||
|
||
$this->load->library('mandrill'); | ||
|
||
$messageMandrill = array( | ||
'html' => $message, | ||
'subject' => $subject, | ||
'from_email' => $email, | ||
'from_name' => $name, | ||
'html' => $this->message, | ||
'subject' => "Contact information", | ||
'from_email' => $this->email, | ||
'from_name' => $this->name, | ||
'to' => array( | ||
array( | ||
'email' => '[email protected]', | ||
|
@@ -323,7 +321,7 @@ function contact() { | |
) | ||
), | ||
'headers' => array( | ||
'Reply-To' => $email, | ||
'Reply-To' => $this->email, | ||
), | ||
'important' => false, | ||
'track_opens' => true, | ||
|
@@ -341,17 +339,17 @@ function contact() { | |
|
||
$scheduleTime = time(); | ||
|
||
$send_at = date('Y-', $scheduleTime).date('m-', $scheduleTime) | ||
.(date('d', $scheduleTime)).' '.(date('H', $scheduleTime)-1).':' | ||
.(date('i', $scheduleTime)).date(':s', $scheduleTime); | ||
$returnValue = date('Y-', $scheduleTime).date('m-', $scheduleTime) | ||
.(date('d', $scheduleTime)).' '.(date('H', $scheduleTime)).':' | ||
.(date('i', $scheduleTime)).':'.(date('s', $scheduleTime)); | ||
|
||
$mandrillResponse = $this->mandrill->messages->send($messageMandrill, $async, $ip_pool, $send_at); | ||
log_message('info', 'Mandrill email: ' . print_r($mandrillResponse, true)); | ||
|
||
|
||
if ($mandrillResponse[0]['status'] === 'sent') { | ||
$result['success'] = true; | ||
} | ||
} | ||
|
||
echo json_encode($result); | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.