From e32f2f1749c691f6c778261a8f8d300573895345 Mon Sep 17 00:00:00 2001 From: vincent-peugnet Date: Wed, 12 Feb 2020 19:44:00 +0100 Subject: Link to refactoring close #48 --- app/class/Page.php | 31 ------------------------------- 1 file changed, 31 deletions(-) (limited to 'app/class/Page.php') diff --git a/app/class/Page.php b/app/class/Page.php index c57ecc4..d5b43b5 100644 --- a/app/class/Page.php +++ b/app/class/Page.php @@ -28,7 +28,6 @@ class Page extends Dbitem protected $customhead; protected $secure; protected $interface; - protected $linkfrom; protected $linkto; protected $templatebody; protected $templatecss; @@ -89,7 +88,6 @@ class Page extends Dbitem $this->setcustomhead(''); $this->setsecure(Config::defaultprivacy()); $this->setinterface('main'); - $this->setlinkfrom([]); $this->setlinkto([]); $this->settemplatebody(''); $this->settemplatecss(''); @@ -257,21 +255,6 @@ class Page extends Dbitem return $this->interface; } - public function linkfrom($option = 'array') - { - if ($option == 'json') { - $linkfrom = json_encode($this->linkfrom); - } elseif ($option == 'array') { - $linkfrom = $this->linkfrom; - } elseif ($option == 'sort') { - return count($this->linkfrom); - } elseif ($option == 'string') { - return implode(', ', $this->linkfrom); - } - return $linkfrom; - - } - public function linkto($option = 'array') { if ($option == 'json') { @@ -597,20 +580,6 @@ class Page extends Dbitem } } - public function setlinkfrom($linkfrom) - { - if (is_array($linkfrom)) { - $this->linkfrom = $linkfrom; - } elseif (is_string($linkfrom)) { - $linkfromjson = json_decode($linkfrom); - if (is_array($linkfromjson)) { - $this->linkfrom = $linkfromjson; - } - } elseif ($linkfrom === null) { - $this->linkfrom = []; - } - } - public function setlinkto($linkto) { if (is_array($linkto)) { -- cgit v1.2.3