1

Topic: worldwide outdoor experience an ultralight hiking blog

Hello together,

I'm running my german ultralight hiking blog since a year with wolfcms.

Thank you for this great keep it simple cms solution, I really enjoy playing around with it!

https://worldwide-outdoor-experience.de/

PS: Currently it is in german only, but for this year i'm planning to translate the page smile

Thumbs up

2

Re: worldwide outdoor experience an ultralight hiking blog

Looks like a clean, clear site. Would I  be right in thinking your design is based on the "Simple" layout? Whether it is or not, (but especially if it is! cool) I'm impressed by how well it works "adaptively" for handhelds.

Hope it all goes well with the translation. There is more that one way to manage that, so it will be good to know what solution you use.

Using Wolf CMS professionally and for profit? Please consider supporting Wolf financially. Thanks!

3

Re: worldwide outdoor experience an ultralight hiking blog

I'm sorry but i started with the lemon layout but found the style too complex, so I removed  most of it. Even the backand is optimized for mobile devices.

Currently there is a lot hardcoded, but I plan to make the changes more configurable and then publish them.

Some nice features from backend side:
Publish articles on specific date by checking the published on timestamp on all pages

Watermark and resize chosen images

Upload docx and convert them with pandoc to HTML and watermark the images.

Thumbs up

4

Re: worldwide outdoor experience an ultralight hiking blog

kImperator wrote:

... Currently there is a lot hardcoded, but I plan to make the changes more configurable and then publish them.

Some nice features from backend side:
Publish articles on specific date by checking the published on timestamp on all pages...

That's very cool. cool I would be interested to know more about how you're managing that.

Using Wolf CMS professionally and for profit? Please consider supporting Wolf financially. Thanks!

5

Re: worldwide outdoor experience an ultralight hiking blog

Oh that was quite easy, I mady only small changes in the sourcecode:

I'm using sqlite3 as database, and I made most of the logic inside the sql. So perhaps you have to modify it for your purpose.

Whenever I want to display subpages, I added an where clause like this:

foreach ($this->children(array('where' => "page.published_on <= DATETIME('now')", 'order' => 'position'), array(), false) as $child) {
     echo "<li>".$child->link()."</li>";
}

So only the published pages would be shown to the user.

In addition to this, I use the archive plugin for blog style for my trips and fotography section. For this plugin I had to modify wolfcms/wolf/plugins/archive/archive.php and add

 "and page.published_on <= DATETIME('now')"

to the corresponding where clauses are inside the sql queries.

For setting the published_on field inside of posts I had to remove the following if clauses from wolfcms/wolf/app/views/page/edit.php:

<?php if (isset($page->published_on)): ?>

Now no article which is not published is shown. But if someone knows the url, it is still accessable. For fixing this I added inside my layout the following if clause:

<?php
$now = new DateTime();
 $str_date= $this->date('%d-%m-%Y %H:%M','published');
 $publishDate = date_create_from_format('d-m-Y H:i', $str_date);
 AuthUser::load();
 if($now > $publishDate || AuthUser::isLoggedIn()) { 
?>
  <?php if($publishDate > $now && AuthUser::isLoggedIn()) { ?>
     <span style="color: red;">LOGGED IN PREVIEW:</span>
  <?php } ?>
  <?php echo $this->content(); ?> 
  <?php if ($this->hasContent('extended')) echo $this->content('extended'); ?> 
<?php
 } else {
echo "This article is currently not published";
 }

Thumbs up +1

6

Re: worldwide outdoor experience an ultralight hiking blog

Very clever, and thanks for documenting here.

Of course, there is always a down-side to "hacking" core things: when an upgrade comes along, that makes maintenance a pain! But I do that with another system (Dokuwiki), so I know sometimes that is worth the pain.

Using Wolf CMS professionally and for profit? Please consider supporting Wolf financially. Thanks!