private function checkSessionS($isLoggedIn, NavigationView $nv) { if ($isLoggedIn == false) { return $nv->renderLink(); } else { if ($isLoggedIn == true) { return ''; } } }
/** * Method that renders all the pages. It takes date/time, navigation object * and view chosen from the the controller. * @param object $dtv DateTimeView * @param object $nv NavigationView * @param object $chosenOption could be any of the views * does not return but writes to output nonetheless */ public function render(DateTimeView $dtv, NavigationView $nv, $chosenOption) { echo '<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>Converter</title> </head> <body> <h1><center>' . $chosenOption->header() . '</center></h1> ' . $nv->renderLink() . ' <div class="container"> ' . $this->response($chosenOption) . ' </div> <center> ' . $chosenOption->getInfo() . ' </center> ' . $dtv->show() . ' </body> </html> '; }