Backend Service
This commit is contained in:
@@ -27,7 +27,7 @@ mailsend:
|
||||
server = "smtp.gmail.com";
|
||||
domain = "mermsemr.com";
|
||||
user = "savvy@chiefsoft.com";
|
||||
pass = "may12002";
|
||||
pass = "may12002!";
|
||||
name = "MERMS EHR";
|
||||
};
|
||||
|
||||
|
||||
@@ -117,18 +117,17 @@ int SMTP2( const char * _server, const char * _from, char * _to, char * _body, c
|
||||
}
|
||||
|
||||
// Google
|
||||
/*
|
||||
snprintf( name, BUF_SIZE, EMAIL_PREFIX"/../src/modules/mailsend -smtp %s -f %s -t %s -d %s -name '%s' +cc +bcc -v -starttls -auth-plain -user %s -pass %s -sub '%s' -M '%s'",
|
||||
_server, _from, _to, _domain, _name, _user, _pass, subject, body != NULL ? body : _body );
|
||||
*//*
|
||||
/*
|
||||
// Virtualmail
|
||||
snprintf( name, BUF_SIZE, EMAIL_PREFIX"/../src/modules/mailsend -smtp %s -f %s -t %s -d %s -name '%s' +cc +bcc -v -port 25 -auth-plain -user %s -pass %s -sub '%s' -M '%s'",
|
||||
_server, _from, _to, _domain, _name, _user, _pass, subject, body != NULL ? body : _body );
|
||||
*/
|
||||
*//*
|
||||
// GoDaddy
|
||||
snprintf( name, BUF_SIZE, EMAIL_PREFIX"/../src/modules/mailsend -smtp %s -f %s -t %s -d %s -name '%s' +cc +bcc -v -port 80 -auth-plain -user %s -pass %s -sub '%s' -M '%s'",
|
||||
_server, _from, _to, _domain, _name, _user, _pass, subject, body != NULL ? body : _body );
|
||||
|
||||
*/
|
||||
logfmt( FLOG_MAX, "Calling MAILSEND: %s", name);
|
||||
|
||||
FILE * p = popen( name, "r" );
|
||||
|
||||
@@ -43,7 +43,7 @@ long MemberLogin(CVars in, CVars &out) {
|
||||
out["stauts"] = "OK";
|
||||
/*LOAD THE SESSION INTO OUT now */
|
||||
load_db_record(out, "SELECT session FROM members_session WHERE member_id=%lu ORDER BY id DESC LIMIT 1", out["member_id"].Long());
|
||||
//Email-bad member_email_calls(in["action"].Long(), out, out);
|
||||
member_email_calls(in["action"].Long(), out, out);
|
||||
//===============================================================================================================================
|
||||
pgsql_query("UPDATE members SET last_login = now() WHERE id = %lu", out["member_id"].Long());
|
||||
// account_email(ACCOUNT_LOGIN_ALERT,out,out); // ALERT CUSTOMER OF LOGIN
|
||||
|
||||
@@ -5,7 +5,6 @@ THIS IS THE USER ENTRY POINT API
|
||||
require '../../backend.php';
|
||||
require '../backend_defines.php';
|
||||
//var_dump($mermsemr->cfgReadChar("database.host"));
|
||||
//phpinfo();
|
||||
|
||||
$endpoints = array(
|
||||
'createuser' => array('POST'),
|
||||
@@ -139,10 +138,8 @@ switch ( $in["action"] ) {
|
||||
// calling the backend
|
||||
$out["internal_return"]= $mermsemr->mermsemr_api($in,$out);
|
||||
|
||||
|
||||
header("HTTP/1.1 200 OK");
|
||||
header("Status: 200 OK");
|
||||
//$out = array_merge($in, $out); // DEBUG
|
||||
echo json_encode(processOutJson($in, $out));
|
||||
exit();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user