diff --git a/api/index.php b/api/index.php
index 77552af46..9e998df84 100644
--- a/api/index.php
+++ b/api/index.php
@@ -22,13 +22,7 @@
ini_set('session.use_cookies', 0);
ini_set("session.gc_maxlifetime", 86400);
- if (defined('ENABLE_GZIP_OUTPUT') && ENABLE_GZIP_OUTPUT &&
- function_exists("ob_gzhandler")) {
-
- ob_start("ob_gzhandler");
- } else {
- ob_start();
- }
+ ob_start();
$input = file_get_contents("php://input");
diff --git a/backend.php b/backend.php
index 2ea396987..030676dcb 100644
--- a/backend.php
+++ b/backend.php
@@ -38,10 +38,6 @@
header("Content-Type: text/json; charset=utf-8");
- if (ENABLE_GZIP_OUTPUT && function_exists("ob_gzhandler")) {
- ob_start("ob_gzhandler");
- }
-
if (SINGLE_USER_MODE) {
UserHelper::authenticate( "admin", null);
}
diff --git a/classes/pref/system.php b/classes/pref/system.php
index d91339698..a7512915a 100644
--- a/classes/pref/system.php
+++ b/classes/pref/system.php
@@ -25,6 +25,15 @@ class Pref_System extends Handler_Protected {
$this->pdo->query("DELETE FROM ttrss_error_log");
}
+ function getphpinfo() {
+ ob_start();
+ phpinfo();
+ $info = ob_get_contents();
+ ob_end_clean();
+
+ print preg_replace( '%^.*
(.*).*$%ms','$1', $info);
+ }
+
private function log_viewer(int $page, int $severity) {
$errno_values = [];
@@ -167,14 +176,11 @@ class Pref_System extends Handler_Protected {
print "";
- ob_start();
- phpinfo();
- $info = ob_get_contents();
- ob_end_clean();
+ print "";
- print "
";
- print preg_replace( '%^.*(.*).*$%ms','$1', $info);
- print "
";
+ print "
" . __("Loading, please wait...") . "
";
print "
"; # accordion pane
diff --git a/config.php-dist b/config.php-dist
index cd0ee0078..2ee1c719d 100644
--- a/config.php-dist
+++ b/config.php-dist
@@ -122,13 +122,6 @@
define('CHECK_FOR_UPDATES', true);
// Check for updates automatically if running Git version
- define('ENABLE_GZIP_OUTPUT', false);
- // Selectively gzip output to improve wire performance. This requires
- // PHP Zlib extension on the server.
- // Enabling this can break tt-rss in several httpd/php configurations,
- // if you experience weird errors and tt-rss failing to start, blank pages
- // after login, or content encoding errors, disable it.
-
define('PLUGINS', 'auth_internal, note');
// Comma-separated list of plugins to load automatically for all users.
// System plugins have to be specified here. Please enable at least one
diff --git a/include/sanity_config.php b/include/sanity_config.php
index 7aa4f6b0f..5059ee83b 100644
--- a/include/sanity_config.php
+++ b/include/sanity_config.php
@@ -1,3 +1,3 @@
-
+$required_defines = array( 'DB_TYPE', 'DB_HOST', 'DB_USER', 'DB_NAME', 'DB_PASS', 'MYSQL_CHARSET', 'SELF_URL_PATH', 'SINGLE_USER_MODE', 'SIMPLE_UPDATE_MODE', 'PHP_EXECUTABLE', 'LOCK_DIRECTORY', 'CACHE_DIR', 'ICONS_DIR', 'ICONS_URL', 'AUTH_AUTO_CREATE', 'AUTH_AUTO_LOGIN', 'FORCE_ARTICLE_PURGE', 'SESSION_COOKIE_LIFETIME', 'SMTP_FROM_NAME', 'SMTP_FROM_ADDRESS', 'DIGEST_SUBJECT', 'CHECK_FOR_UPDATES', 'PLUGINS', 'LOG_DESTINATION', 'CONFIG_VERSION'); ?>
diff --git a/js/PrefHelpers.js b/js/PrefHelpers.js
index 5bb76d179..3b9e985a6 100644
--- a/js/PrefHelpers.js
+++ b/js/PrefHelpers.js
@@ -51,6 +51,13 @@ const Helpers = {
return false;
},
+ System: {
+ getPHPInfo: function(widget) {
+ xhrPost("backend.php", {op: 'pref-system', method: 'getphpinfo'}, (transport) => {
+ widget.attr('content', transport.responseText);
+ });
+ }
+ },
EventLog: {
log_page: 0,
refresh: function() {
diff --git a/public.php b/public.php
index 36308e25e..3e4a9e023 100644
--- a/public.php
+++ b/public.php
@@ -16,10 +16,6 @@
if (!init_plugins()) return;
- if (ENABLE_GZIP_OUTPUT && function_exists("ob_gzhandler")) {
- ob_start("ob_gzhandler");
- }
-
$method = $_REQUEST["op"];
$override = PluginHost::getInstance()->lookup_handler("public", $method);