From f4cc4491774388431f78977a168efac99aca72e1 Mon Sep 17 00:00:00 2001 From: dignajar Date: Sun, 25 Sep 2016 15:38:15 -0300 Subject: [PATCH] Updates --- bl-plugins/api/plugin.php | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/bl-plugins/api/plugin.php b/bl-plugins/api/plugin.php index cbfe7e82..f60ae555 100644 --- a/bl-plugins/api/plugin.php +++ b/bl-plugins/api/plugin.php @@ -7,10 +7,10 @@ class pluginAPI extends Plugin { global $Security; // This key is used for request such as get the list of all posts and pages - $authKey = md5($Security->key1().time().DOMAIN_BASE); + $authKey = md5($Security->key1().time().DOMAIN); $this->dbFields = array( - 'ping'=>0, // 0 = false, 1 = true + 'ping'=>1, // 0 = false, 1 = true 'authKey'=>$authKey, // Private key 'showAllAmount'=>15 // Amount of posts and pages for return ); @@ -60,6 +60,13 @@ class pluginAPI extends Plugin { $this->ping(); } + public function install($position=0) + { + parent::install($position); + + $this->ping(); + } + private function ping() { if($this->getDbField('ping')) { @@ -76,7 +83,6 @@ class pluginAPI extends Plugin { curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_HEADER, false); curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false); - curl_setopt($ch, CURLOPT_SSLVERSION, 3); $out = curl_exec($ch); if($out === false) {