uriData = $uriData; $this->DIR = __DIR__ ?: dirname(__FILE__); $this->controller = new indexController($this->uriData, $this->DIR, basename($this->DIR)); } public function pageIndexAction() { if (getG('scroll_to')) { $this->controller->sScrollTo->scrollTo = getG('scroll_to'); redirectToUri($this->controller->gL()); } $action = getV('action'); if (!$action) { $action = getV('a'); } switch ($action) { case 'file': $this->controller->requestFileDownload(getG('f'), getG('p')); break; case 'subscribe': $this->controller->addUserToSubscriptionList(getV('data')); break; case 'unsubscribe': $this->controller->removeUserFromSubscriptionList(getV('data')); break; default: $this->controller->runIndex(); break; } } public function pageCookiesAction() { $action = getV('a'); if (!$action) { $action = getV('action'); } switch ($action) { case 'accept-cookies': cJSON::sendOk($this->controller->acceptCookiePolicy()); break; case 'accept-all-cookies': cJSON::sendOk($this->controller->acceptCookiePolicy(true)); break; default: $this->controller->runCookies(); break; } } public function pageAgreeToTermsAction() { $this->controller->runTermsOfUsage(); } public function contactUsAction() { $action = getV('a'); if (!$action) { $action = getV('action'); } switch ($action) { case 'contact_us': $this->controller->contactUs(getV('data')); break; default: $this->controller->runContactUs(); break; } } public function pageAboutUsAction() { $this->controller->runAboutUs(); } public function pageFaqAction() { $this->controller->runFaq(); } public function pageDisclaimersAction() { $this->controller->runDisclaimer(); } public function pagePrivacyPolicyAction() { $this->controller->runPrivacyPolicy(); } public function pagePaymentPolicyAction() { $this->controller->runPaymentPolicy(); } public function pageReturnPolicyAction() { $this->controller->runReturnPolicy(); } public function pageShippingPolicyAction() { $this->controller->runShippingPolicy(); } public function pageUnSubscribeAction() { $action = getV('action'); if (!$action) { $action = getV('a'); } switch ($action) { case 'unsubscribe': $this->controller->removeUserFromSubscriptionList(getV('data')); break; default: $this->controller->runUnSubscribe(); break; } } public function pageSubscribeAction() { $action = getV('action'); if (!$action) { $action = getV('a'); } switch ($action) { case 'subscribe': $this->controller->addUserToSubscriptionList(getV('data')); break; default: $this->controller->runSubscribe(); break; } } public function pageCopyRightsAction() { $this->controller->runCopyRights(); } public function pageAccessErrorAction() { $this->controller->runAccessError(); } public function blankAction(): bool { return true; } }