SilverWare\Blog\Pages\BlogController
An extension of the page controller class for a blog controller.
- Author: Colin Tucker <colin@praxis.net.au>
- Copyright: 2017 Praxis Interactive
- License: https://opensource.org/licenses/BSD-3-Clause BSD-3-Clause
Synopsis
class BlogController
extends PageController
{
- // members
- private static array $url_handlers = ;
- private static array $allowed_actions = ;
- // methods
- public HTTPResponse|DBHTMLText|array index()
- public HTTPResponse|DBHTMLText|array rss()
- public HTTPResponse|DBHTMLText|array archive()
- public HTTPResponse|DBHTMLText|array author()
- public HTTPResponse|DBHTMLText|array tag()
- public Blog getBlog()
- public Member getCurrentAuthor()
- public BlogTag getCurrentTag()
- public ArrayList getExtraBreadcrumbItems()
- public Breadcrumb getExtraBreadcrumb()
- protected void init()
- protected string getFormattedMonthAndYear()
Hierarchy
Extends
- PageController
Members
private
- $allowed_actions
—
array
Defines the allowed actions for this controller. - $url_handlers
—
array
Defines the URLs handled by this controller.
Methods
protected
- getFormattedMonthAndYear() — Answers a formatted string for the given month and year.
- init() — Performs initialisation before any action is called on the receiver.
public
- archive() — Renders a list of the blog posts for the requested year and optional month.
- getBlog() — Answers the associated blog record.
- getCurrentAuthor() — Answers the author associated with the current request.
- getCurrentTag() — Answers the blog tag associated with the current request.
- getExtraBreadcrumb() — Answers an extra breadcrumb object for the current request.
- getExtraBreadcrumbItems() — Answers a list of extra breadcrumb items for the template.
- index() — Default action for this controller, either render the blog or redirect to an existing post.
- rss() — Renders a list of the latest blog posts as an RSS feed.
- tag() — Renders a list of the blog posts matching the requested tag.