styling, navigation bar, theming, article lists, page routing.
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
<?php
|
||||
require_once 'functions/init.php';
|
||||
require_once 'functions/functions.php';
|
||||
|
||||
include_once 'components/head.php';
|
||||
|
||||
include_once 'functions/article_functions.php';
|
||||
|
||||
// TODO: Move to a grid, where the left hand column is either a search and filtering system, or...Table of Contents?
|
||||
|
||||
// Default view, it'll show articles by recency
|
||||
if (!isset($_GET['article_id']) && !isset($_GET['tag'])) {
|
||||
$ids = article_ids_by_recency();
|
||||
|
||||
foreach ($ids as $id) {
|
||||
echo article_card($id);
|
||||
}
|
||||
} else if (isset($_GET['article_id'])) {
|
||||
echo article_page_from_markdown($_GET['article_id']);
|
||||
} else if (isset($_GET['tag'])) {
|
||||
$ids = article_ids_by_tag($_GET['tag']);
|
||||
|
||||
foreach ($ids as $id) {
|
||||
echo article_card($id);
|
||||
}
|
||||
}
|
||||
|
||||
include_once 'components/foot.php';
|
||||
Reference in New Issue
Block a user