Example post: how this blog works

Example content — this is a placeholder post, not a real company update.

This is an example post included with the TRIFORGE site so the blog listing has something to show. It is not a real company announcement, and nothing in it describes real work, real clients, or real results. Delete this file once you publish your first genuine post.

Where posts live

Every post is a single JSON file in the content/posts directory. The filename is the URL slug: this file is example-welcome.json, so it is served at blog/post.php?slug=example-welcome. There is no database and no build step — adding a file publishes a post, and deleting a file unpublishes it.

What a post file contains

  • title — shown as the page heading and in the listing
  • date — ISO format (YYYY-MM-DD); the listing sorts newest first
  • excerpt — one or two sentences shown on the listing page
  • example — optional; set it to true to show the placeholder banner above
  • body — an array of content blocks, described below

Body blocks

The body is an array rather than one long string of HTML. Each block names its own type, so the template decides how it renders and the text is always escaped on output. That means a post file can never inject markup or script into the page, even if someone pastes something unexpected into it.

  • { "type": "p", "text": "..." } — a paragraph
  • { "type": "h2", "text": "..." } — a subheading
  • { "type": "ul", "items": ["...", "..."] } — a bulleted list

Any block type the template does not recognise is skipped rather than printed raw, so a typo degrades to missing content instead of broken markup.

← All posts