Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add side nav bar #37

Merged
merged 2 commits into from
Sep 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion app/libraries/Core.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,16 @@ class Core {

public function __construct(){
$url = $this->getURL();
// CHeck requested controller is existing in the controllers folder
// Check user request null controller
if (ucwords($url[0]) == null){
// If null, then load the default controller
require_once '../app/controllers/Pages.php';
$this->currentController = new Pages;
$this->currentController->index();
return;
}

// Check requested controller is existing in the controllers folder
if (file_exists('../app/controllers/'.ucwords($url[0]).'.php')){
// If the controller exists, then load it
$this->currentController = ucwords($url[0]);
Expand Down
40 changes: 40 additions & 0 deletions app/libraries/Exception.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
<?php

/**
* PHPMailer Exception class.
* PHP Version 5.5.
*
* @see https://github.com/PHPMailer/PHPMailer/ The PHPMailer GitHub project
*
* @author Marcus Bointon (Synchro/coolbru) <phpmailer@synchromedia.co.uk>
* @author Jim Jagielski (jimjag) <jimjag@gmail.com>
* @author Andy Prevost (codeworxtech) <codeworxtech@users.sourceforge.net>
* @author Brent R. Matzelle (original founder)
* @copyright 2012 - 2020 Marcus Bointon
* @copyright 2010 - 2012 Jim Jagielski
* @copyright 2004 - 2009 Andy Prevost
* @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License
* @note This program is distributed in the hope that it will be useful - WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE.
*/

namespace PHPMailer\PHPMailer;

/**
* PHPMailer exception handler.
*
* @author Marcus Bointon <phpmailer@synchromedia.co.uk>
*/
class Exception extends \Exception
{
/**
* Prettify error message output.
*
* @return string
*/
public function errorMessage()
{
return '<strong>' . htmlspecialchars($this->getMessage(), ENT_COMPAT | ENT_HTML401) . "</strong><br />\n";
}
}
Loading
Loading