(franken)log

dev site for hy(de)blog

2023-02-18 Saturday

That was easy.

Nothing much to do for /feeds or /colophon other than: 1

  • add in a $title variable declaration so that the pages play nice with the new header.php include
  • Add in the BASE_URL variable to all of the resource urls in header.php (style.css, js etc.) so that the pages contained with in subfolders have access to those files without having to custom build anything.

I could invest more time in these pages, to make them editable, but that's not really a need at the moment (or ever?). The only tweaks would be:

  • /feeds: if I make the main feed selectable (entries or daily) then I could need to update this page to reflect that choice.
  • /colophon: once ready for release, this page should be updated to include my work too.

  1. Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. 

Comments

Have something you'd like to respond with? 📣

Send me a note via email and let's start a conversation on this very topic.

I was having some issues with the ampersand causing the rss-daily.xml to be invalid.

As a temporary measure I've added the following into line 82 of rss.php:

$post_title = str_replace(array('&', '<'), array('&', '<'), $post_title);

This should solve the main issue for the time being. There may be a better solution that accounts for a wider range of special character issues. I will have to look into it later.

Reference: php - RSS Feed & Special Characters - Stack Overflow

Comments

Have something you'd like to respond with? 📣

Send me a note via email and let's start a conversation on this very topic.

I was having an issue with the sidebar not displaying the user generated pages when on the newly templates /feed and /pages. Additionally, I noticed that the site did not recognize that I was logged in when viewing those pages (the login/admin icons in the sidebar were not auto updating as they should).

I realized that the cause was related to not knowing what directory to look in, for both the user generated pages (which is needed for the sidebar) or for the sessions file (which is needed for authentication).

I added the following code to both the feeds.php and colophon.php files:

$target_dir =  dirname(__DIR__);
$auth = file_get_contents($target_dir . '/session.php');

Comments

Have something you'd like to respond with? 📣

Send me a note via email and let's start a conversation on this very topic.

I was finding some conflicts between the use of $rootvs $target_dir for the same purposes. I'm not sure if I created this conflict, if some inconsistencies pre-existed me, or a combination of the two. Regardless, I was finding that the issue I came across earlier was more widespread than just the two static pages I initial thought it affected.

I've cleaned up the error where I currently see it, and have $root being used more consistently for— the root directory of the platform install, but I will have to keep a look out for other instances of this issue as I move along.

Comments

Have something you'd like to respond with? 📣

Send me a note via email and let's start a conversation on this very topic.

With a solid few hours I think I have all of the parts of this platform templated with common headers, footers, and sidebar. I think I've account for most of the issues with displaying page names across the site. And, I think I have body classes (and titles) built into every page/post where they can be useful.

There's a bunch of clean up to be done, and a few minor bugs to squash, but it's looking like I'll be comfortable with rolling out this version to https://log.kvl.me by mid next week.

Lots of ideas moving through my head on what to tackle next.

Comments

Have something you'd like to respond with? 📣

Send me a note via email and let's start a conversation on this very topic.