4 * will display the couchdb log
7 * @link http://www.open-emr.org
8 * @author Brady Miller <brady.g.miller@gmail.com>
9 * @copyright Copyright (c) 2019 Brady Miller <brady.g.miller@gmail.com>
10 * @license https://github.com/openemr/openemr/blob/master/LICENSE GNU General Public License 3
13 require_once("../globals.php");
15 use OpenEMR\Common\Crypto\CryptoGen
;
17 $filename = $GLOBALS['OE_SITE_DIR'] . '/documents/couchdb/log.txt';
19 if (!file_exists($filename)) {
20 echo xlt("CouchDB error log is empty");
24 $fh = file_get_contents($filename);
26 $cryptoGen = new CryptoGen();
27 if ($cryptoGen->cryptCheckStandard($fh)) {
28 $fh = $cryptoGen->decryptStandard($fh, null, 'database');
32 echo nl2br(text($fh));
34 echo xlt("CouchDB error log is empty");