Archives Page - For Small Forums
Archives Page - For Small Forums
df0b2 Friday 12th February 2016, 23:23:51Hi Fred,
Can you help me to get a code to work?
I want to have an archive page that is like so.
# 2016
**Dec**
* 30 - title
* 01 - title
**Jan**
* 20 - title
# 2015
**Nov**
* 30 - title
* 01 - title
*
This code from goolog is here, but does not show all years... only shows one year each page:
https://github.com/ciptard/goolog/blob/master/view.php#L67
How can I make this work with FB?
Can you help me to get a code to work?
I want to have an archive page that is like so.
# 2016
**Dec**
* 30 - title
* 01 - title
**Jan**
* 20 - title
# 2015
**Nov**
* 30 - title
* 01 - title
*
This code from goolog is here, but does not show all years... only shows one year each page:
https://github.com/ciptard/goolog/blob/master/view.php#L67
else if(isGET('archive') && strlen($_GET['archive']) === 4)
{
$archivedPosts = array();
$posts = listEntry('post');
sort($posts);
foreach($posts as $post)
{
if($_GET['archive'] === substr($post, 0, 4))
{
$month = substr($post, 5, 2);
$archivedPosts[$month][] = $post;
}
}
if(!$archivedPosts)
{
exit;
}
$out['subtitle'] = $_GET['archive'];
foreach($archivedPosts as $monthPosts)
{
$out['content'] .= '<b>' .toDate($monthPosts[0], 'M'). '</b>
<ul>';
foreach($monthPosts as $post)
{
$postEntry = readEntry('post', $post);
$out['content'] .= '<li>' .toDate($post, 'jS'). ' - ' .managePost($post). '<a href="view.php/post/' .$post. '">' .$postEntry['title']. '</a></li>';
}
$out['content'] .= '</ul>';
}
}
How can I make this work with FB?
Last modified by Fred on Sunday 16th May 2021, 09:53:00
Fred locked the discussion.
Replies 5
A plugin will arrive very soon to meet your needs, you can [try it here](view.php/plugin/archives) and tell me if it suits you.
- Before ask a question, read the documentation.
- 🎉 Featured as #1 product of the day on Product Hunt
- Please like in alternativeto.net 👍🏻
- ╰☆╮Flatboard╰☆╮ is a open source and community contributions are essential to project success!
- <TextField>, my new CMS project designed by a passionate developer, for developers!
- I am currently busy 😫.
Just display a full year it takes a lot of server resources, then with all the years ...
No it is inconceivable in flat-files, also it would be unreadable.
No it is inconceivable in flat-files, also it would be unreadable.
- Before ask a question, read the documentation.
- 🎉 Featured as #1 product of the day on Product Hunt
- Please like in alternativeto.net 👍🏻
- ╰☆╮Flatboard╰☆╮ is a open source and community contributions are essential to project success!
- <TextField>, my new CMS project designed by a passionate developer, for developers!
- I am currently busy 😫.
Try with a [.htaccess and rewrite rules](https://httpd.apache.org/docs/trunk/en/rewrite/intro.html).
I do not want to change the url rewriting of flatboard because flatboard just has the big advantage to turn without .htaccess file, therefore compatible in many servers.
I do not want to change the url rewriting of flatboard because flatboard just has the big advantage to turn without .htaccess file, therefore compatible in many servers.
- Before ask a question, read the documentation.
- 🎉 Featured as #1 product of the day on Product Hunt
- Please like in alternativeto.net 👍🏻
- ╰☆╮Flatboard╰☆╮ is a open source and community contributions are essential to project success!
- <TextField>, my new CMS project designed by a passionate developer, for developers!
- I am currently busy 😫.
Suggested Topics
mk@b8500609
started Avatars and Pseudo case sensitive
General Questions
bb4d0
started solved Events?
General Questions
AlexanderLiebrecht
started plugin Search Engine friendly URLs for Flatboard
Feature Requests
Fred
started plugin Archives
Resources