Add multi-file page support and improve documentation
Update README to explain multi-file page functionality Add example content files demonstrating the feature Improve folder type detection logic Implement new routing for page-type folders Add support for mixed content types in single pages Update navigation and metadata handling for multi-file pages Remove legacy frontpage.php in favor of multi-file approach Improve file-based routing documentation Add examples of different content types working together Update router to handle multi-file content rendering Implement proper sorting of content files Add best practices for multi-file content organization
This commit is contained in:
parent
f2c18659dc
commit
b507a0c676
20 changed files with 458 additions and 240 deletions
15
app/default/content/about/00-introduction.md
Normal file
15
app/default/content/about/00-introduction.md
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
# About FolderWeb
|
||||
|
||||
FolderWeb is a minimalist PHP framework designed for simplicity, longevity, and maintainability. It's built on a simple philosophy: **just enough, nothing more**.
|
||||
|
||||
## Philosophy
|
||||
|
||||
Modern web development has become unnecessarily complex. Build tools, package managers, JavaScript frameworks that change every few months—it's exhausting and unsustainable.
|
||||
|
||||
FolderWeb is different. It's built to:
|
||||
|
||||
- **Work for decades** without requiring constant updates
|
||||
- **Be understandable** by reading a few hundred lines of code
|
||||
- **Stay maintainable** without specialized knowledge
|
||||
- **Load fast** with no JavaScript overhead
|
||||
- **Just work** without configuration or setup
|
||||
15
app/default/content/about/01-design-principles.html
Normal file
15
app/default/content/about/01-design-principles.html
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
<article>
|
||||
<h2>Design Principles</h2>
|
||||
|
||||
<h3>Minimalism</h3>
|
||||
<p>Use only what is strictly necessary. No frameworks, no build tools, no package managers for frontend code. Every line of code must justify its existence.</p>
|
||||
|
||||
<h3>File-Based Everything</h3>
|
||||
<p>Your folder structure is your URL structure. Drop a file in a folder and it's instantly accessible. No routes to configure, no databases to set up.</p>
|
||||
|
||||
<h3>Override, Never Modify</h3>
|
||||
<p>Custom templates and styles go in <code>/custom/</code> and automatically override defaults. The core files in <code>/app/default/</code> remain untouched and updateable.</p>
|
||||
|
||||
<h3>Modern Standards</h3>
|
||||
<p>Use modern PHP 8.3+ features and modern CSS capabilities. Avoid JavaScript entirely—it's not needed for content-focused sites.</p>
|
||||
</article>
|
||||
21
app/default/content/about/02-technology-stack.php
Normal file
21
app/default/content/about/02-technology-stack.php
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
<article>
|
||||
<h2>Technology Stack</h2>
|
||||
|
||||
<h3>Backend</h3>
|
||||
<ul>
|
||||
<li><strong>PHP 8.3+</strong> - Modern PHP with type hints, arrow functions, match expressions</li>
|
||||
<li><strong>Apache</strong> - With mod_rewrite for clean URLs</li>
|
||||
<li><strong>Parsedown</strong> - Simple, reliable Markdown parser</li>
|
||||
</ul>
|
||||
|
||||
<h3>Frontend</h3>
|
||||
<ul>
|
||||
<li><strong>HTML5</strong> - Semantic markup following best practices</li>
|
||||
<li><strong>CSS3</strong> - Modern features like Grid, clamp(), OKLCH colors, CSS nesting</li>
|
||||
<li><strong>No JavaScript</strong> - By design, for faster loads and simpler maintenance</li>
|
||||
</ul>
|
||||
|
||||
<aside style="background: #f5f5f5; padding: 1rem; border-left: 4px solid #333; margin: 2rem 0;">
|
||||
<p><strong>Note:</strong> This section demonstrates using PHP for dynamic content. The current date is: <strong><?= date('F j, Y') ?></strong></p>
|
||||
</aside>
|
||||
</article>
|
||||
19
app/default/content/about/03-what-it-is-not.md
Normal file
19
app/default/content/about/03-what-it-is-not.md
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
## What It's Not
|
||||
|
||||
FolderWeb is **not**:
|
||||
|
||||
- A CMS with an admin panel
|
||||
- A single-page application framework
|
||||
- A solution for complex web applications
|
||||
- Trying to scale to millions of users
|
||||
- Following current trends and fads
|
||||
|
||||
## What It Is
|
||||
|
||||
FolderWeb **is**:
|
||||
|
||||
- A simple way to publish content
|
||||
- A foundation that will work for decades
|
||||
- A teaching tool for web fundamentals
|
||||
- A protest against unnecessary complexity
|
||||
- Perfect for documentation, blogs, portfolios, small business sites
|
||||
21
app/default/content/about/04-get-started.md
Normal file
21
app/default/content/about/04-get-started.md
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
## Get Started
|
||||
|
||||
Ready to build something simple and lasting?
|
||||
|
||||
1. Create a `/content` folder
|
||||
2. Add your first `.md` file
|
||||
3. That's it—you're publishing
|
||||
|
||||
No build step. No npm install. No configuration files. Just content.
|
||||
|
||||
---
|
||||
|
||||
**This page demonstrates FolderWeb's multi-file approach.** Notice how this page is built from multiple files that render in alphanumerical order:
|
||||
|
||||
- `00-introduction.md` - Markdown content
|
||||
- `01-design-principles.html` - Static HTML
|
||||
- `02-technology-stack.php` - Dynamic PHP (shows current date)
|
||||
- `03-what-it-is-not.md` - More Markdown
|
||||
- `04-get-started.md` - This section
|
||||
|
||||
Mix file types freely. They all render together seamlessly!
|
||||
|
|
@ -1,89 +0,0 @@
|
|||
# About FolderWeb
|
||||
|
||||
FolderWeb is a minimalist PHP framework designed for simplicity, longevity, and maintainability. It's built on a simple philosophy: **just enough, nothing more**.
|
||||
|
||||
## Philosophy
|
||||
|
||||
Modern web development has become unnecessarily complex. Build tools, package managers, JavaScript frameworks that change every few months—it's exhausting and unsustainable.
|
||||
|
||||
FolderWeb is different. It's built to:
|
||||
|
||||
- **Work for decades** without requiring constant updates
|
||||
- **Be understandable** by reading a few hundred lines of code
|
||||
- **Stay maintainable** without specialized knowledge
|
||||
- **Load fast** with no JavaScript overhead
|
||||
- **Just work** without configuration or setup
|
||||
|
||||
## Design Principles
|
||||
|
||||
### Minimalism
|
||||
Use only what is strictly necessary. No frameworks, no build tools, no package managers for frontend code. Every line of code must justify its existence.
|
||||
|
||||
### File-Based Everything
|
||||
Your folder structure is your URL structure. Drop a file in a folder and it's instantly accessible. No routes to configure, no databases to set up.
|
||||
|
||||
### Override, Never Modify
|
||||
Custom templates and styles go in `/custom/` and automatically override defaults. The core files in `/app/default/` remain untouched and updateable.
|
||||
|
||||
### Modern Standards
|
||||
Use modern PHP 8.3+ features and modern CSS capabilities. Avoid JavaScript entirely—it's not needed for content-focused sites.
|
||||
|
||||
## Technology Stack
|
||||
|
||||
### Backend
|
||||
- **PHP 8.3+** - Modern PHP with type hints, arrow functions, match expressions
|
||||
- **Apache** - With mod_rewrite for clean URLs
|
||||
- **Parsedown** - Simple, reliable Markdown parser
|
||||
|
||||
### Frontend
|
||||
- **HTML5** - Semantic markup following best practices
|
||||
- **CSS3** - Modern features like Grid, clamp(), OKLCH colors, CSS nesting
|
||||
- **No JavaScript** - By design, for faster loads and simpler maintenance
|
||||
|
||||
## What It's Not
|
||||
|
||||
FolderWeb is **not**:
|
||||
|
||||
- A CMS with an admin panel
|
||||
- A single-page application framework
|
||||
- A solution for complex web applications
|
||||
- Trying to scale to millions of users
|
||||
- Following current trends and fads
|
||||
|
||||
## What It Is
|
||||
|
||||
FolderWeb **is**:
|
||||
|
||||
- A simple way to publish content
|
||||
- A foundation that will work for decades
|
||||
- A teaching tool for web fundamentals
|
||||
- A protest against unnecessary complexity
|
||||
- Perfect for documentation, blogs, portfolios, small business sites
|
||||
|
||||
## Use Cases
|
||||
|
||||
FolderWeb excels at:
|
||||
|
||||
- **Documentation sites** - Clear structure, easy to navigate
|
||||
- **Personal blogs** - Simple publishing workflow
|
||||
- **Portfolio sites** - Showcase your work without bloat
|
||||
- **Small business sites** - Professional presence without complexity
|
||||
- **Project pages** - Quick site for your open source project
|
||||
|
||||
## Who Created This?
|
||||
|
||||
FolderWeb emerged from frustration with modern web development complexity. It's built for developers who appreciate simplicity and maintainability over features and frameworks.
|
||||
|
||||
## License
|
||||
|
||||
FolderWeb is open source. Check the repository for license details.
|
||||
|
||||
## Get Started
|
||||
|
||||
Ready to build something simple and lasting?
|
||||
|
||||
1. Create a `/content` folder
|
||||
2. Add your first `.md` file
|
||||
3. That's it—you're publishing
|
||||
|
||||
No build step. No npm install. No configuration files. Just content.
|
||||
Loading…
Add table
Add a link
Reference in a new issue