From f8906282ef5a56b340ec97e6b65f556124732bd3 Mon Sep 17 00:00:00 2001 From: hauke Date: Thu, 24 Dec 2015 11:20:37 +0100 Subject: [PATCH] added skeletons for help and stats page, text adjustements --- dfrndir.sql | 2 +- include/site-health.php | 6 ++++++ mod/help.php | 10 ++++++++++ mod/stats.php | 10 ++++++++++ src/templates/layout/_navigation.php | 2 +- src/templates/view/help.php | 9 +++++++++ src/templates/view/homepage.php | 5 ++--- src/templates/view/stats.php | 5 +++++ 8 files changed, 44 insertions(+), 5 deletions(-) create mode 100644 mod/help.php create mode 100644 mod/stats.php create mode 100644 src/templates/view/help.php create mode 100644 src/templates/view/stats.php diff --git a/dfrndir.sql b/dfrndir.sql index b36c8a65..f019a274 100644 --- a/dfrndir.sql +++ b/dfrndir.sql @@ -167,7 +167,7 @@ CREATE TABLE IF NOT EXISTS `site-health` ( `admin_name` varchar(255) NULL DEFAULT NULL, `admin_profile` varchar(255) NULL DEFAULT NULL, `ssl_state` bit(1) NULL DEFAULT NULL, - `ssl_grade` varchar(2) NULL DEFAULT NULL, + `ssl_grade` varchar(3) NULL DEFAULT NULL, PRIMARY KEY (`id`), KEY `base_url` (`base_url`), KEY `health_score` (`health_score`), diff --git a/include/site-health.php b/include/site-health.php index c9ed4f92..bf94ad35 100644 --- a/include/site-health.php +++ b/include/site-health.php @@ -91,6 +91,12 @@ function parse_site_from_url($url) //Performs a ping to the given site ID //You may need to notice the site first before you know it's ID. +//TODO: Probe server location using IP address or using the info the friendica server provides (preferred). +// If IP needs to be used only provide country information. +//TODO: Check SSLLabs Grade +// Check needs to be asynchronous, meaning that the check at SSLLabs will be initiated in one run while +// the results must be fetched later. It might be good to mark sites, where a check has been inititated +// f.e. using the ssl_grade field. In the next run, results of these sites could be fetched. if(! function_exists('run_site_probe')){ function run_site_probe($id, &$entry_out) { diff --git a/mod/help.php b/mod/help.php new file mode 100644 index 00000000..db14e7a6 --- /dev/null +++ b/mod/help.php @@ -0,0 +1,10 @@ +output(); + } +} + diff --git a/mod/stats.php b/mod/stats.php new file mode 100644 index 00000000..866b33cd --- /dev/null +++ b/mod/stats.php @@ -0,0 +1,10 @@ +output(); + } +} + diff --git a/src/templates/layout/_navigation.php b/src/templates/layout/_navigation.php index bdaf5bf2..4aa57bb1 100644 --- a/src/templates/layout/_navigation.php +++ b/src/templates/layout/_navigation.php @@ -2,7 +2,7 @@