From 746f293d22748cc09af2c859c5b6143842e00313 Mon Sep 17 00:00:00 2001 From: ArtemKo7v Date: Tue, 4 Apr 2017 14:52:59 +0700 Subject: [PATCH] Config structure updated --- .htaccess | 4 ++ index.php | 83 +++++++++++---------------------------- js/ethplorer.js | 3 ++ robots.txt | 1 + service/config.sample.php | 3 ++ service/lib/ethplorer.php | 8 ++-- widgets.html | 69 +++++++------------------------- 7 files changed, 53 insertions(+), 118 deletions(-) diff --git a/.htaccess b/.htaccess index bac7eda7..cef7ebd7 100644 --- a/.htaccess +++ b/.htaccess @@ -7,8 +7,12 @@ RewriteRule ^top$ page627210.html RewriteRule ^about$ page627364.html RewriteRule ^privacy$ page627373.html +RewriteCond %{REQUEST_FILENAME} !-f +RewriteCond %{REQUEST_FILENAME} !-d +RewriteRule ^js/config.js$ config.php [L,QSA] RewriteRule ^widgets$ widgets.html + RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^tx/(.*) index.php [L,QSA] diff --git a/index.php b/index.php index b30729ba..2d6126d4 100644 --- a/index.php +++ b/index.php @@ -18,16 +18,14 @@ $codeVersion = "141"; require dirname(__FILE__) . '/service/lib/ethplorer.php'; -$esCfg = require_once dirname(__FILE__) . '/service/config.php'; -$esCfg['mongo'] = FALSE; // No mongo connection -$es = Ethplorer::db($esCfg); +$es = Ethplorer::db(array()); $error = TRUE; $header = ""; $uri = $_SERVER['REQUEST_URI']; // Uri to lowercase -if(preg_match("/[A-Z]+/", $uri)){ +if(preg_match("/[A-Z]+/", $uri) && (FALSE === strpos($uri, '1dea4'))){ header("Location: " . strtolower($uri)); die(); } @@ -81,6 +79,7 @@ + @@ -567,28 +566,6 @@ (d.head || d.body).appendChild(s); })(); - - -
-
- About -     - Discuss ethplorer -     - Sources -     - API -
-
- (c) 2016 Everex -     - support@ethplorer.io
- Privacy & Terms -
-
- - */ ?>