diff --git a/index.php b/index.php
index 7ebb1db..4c8d3c4 100644
--- a/index.php
+++ b/index.php
@@ -346,6 +346,15 @@ public function getUserLoginStatus()
return $this->user_is_logged_in;
}
+ /**
+ * Show feedback function, you can custom the way it's shown
+ */
+ private function showFeedback(){
+ if ($this->feedback) {
+ echo $this->feedback . "
";
+ }
+ }
+
/**
* Simple demo-"page" that will be shown when the user is logged in.
* In a real application you would probably include an html-template here, but for this extremely simple
@@ -353,9 +362,7 @@ public function getUserLoginStatus()
*/
private function showPageLoggedIn()
{
- if ($this->feedback) {
- echo $this->feedback . "
";
- }
+ $this->showFeedback();
echo 'Hello ' . $_SESSION['user_name'] . ', you are logged in.
';
echo 'Log out';
@@ -368,9 +375,7 @@ private function showPageLoggedIn()
*/
private function showPageLoginForm()
{
- if ($this->feedback) {
- echo $this->feedback . "
";
- }
+ $this->showFeedback();
echo '