diff --git a/controller/action/ContentActions.class.php b/controller/action/ContentActions.class.php index 4dd6463c..327fbc9c 100644 --- a/controller/action/ContentActions.class.php +++ b/controller/action/ContentActions.class.php @@ -353,7 +353,10 @@ class ContentActions extends Actions return [ 'authorName' => $post->getAuthorName(), 'photoImgSrc' => $post->getAuthorPhoto(), - 'authorBioHtml' => $post->getAuthorBioHtml() + 'authorBioHtml' => $post->getAuthorBioHtml(), + 'authorGithub' => $post->getAuthorGithubID(), + 'authorTwitter' => $post->getAuthorTwitterID(), + 'authorEmail' => $post->getAuthorPostEmail() ]; } diff --git a/model/Post.class.php b/model/Post.class.php index a090683f..f54a6a88 100644 --- a/model/Post.class.php +++ b/model/Post.class.php @@ -156,6 +156,30 @@ class Post return $this->author; } + public function getAuthorGithubID() + { + $post = ContentActions::prepareBioPartial(['person' =>$this->author]); + if(array_key_exists("github", $post)){ + return $post["github"]; + } + } + +public function getAuthorTwitterID() +{ + $post = ContentActions::prepareBioPartial(['person' =>$this->author]); + if(array_key_exists("twitter", $post)){ + return $post["twitter"]; + } +} + +public function getAuthorEmail() +{ + $post = ContentActions::prepareBioPartial(['person' =>$this->author]); + if(array_key_exists("email", $post)){ + return $post["email"]; + } +} + public function getDate() { return $this->date; @@ -232,7 +256,7 @@ class Post return $post["name"]; } - public function getAuthorEmail() + public function getAuthorPostEmail() { $post = ContentActions::prepareBioPartial(['person' =>$this->author]); diff --git a/view/template/content/_postAuthor.php b/view/template/content/_postAuthor.php index ea9ea4a7..bc742e71 100644 --- a/view/template/content/_postAuthor.php +++ b/view/template/content/_postAuthor.php @@ -6,9 +6,17 @@
diff --git a/web/scss/_blog.scss b/web/scss/_blog.scss index 61813d86..ae3b0623 100644 --- a/web/scss/_blog.scss +++ b/web/scss/_blog.scss @@ -203,5 +203,5 @@ .post-author-spotlight { - h3 { text-transform: uppercase; margin-top: $spacing-vertical / 4 !important; } + h3 { text-transform: uppercase; margin-top: $spacing-vertical / 4 !important; margin-bottom: 0;} } - +