Compare commits

..

No commits in common. "cef370ca0c6a09a7a20defebd58180930381d647" and "9be457f17ff071088bb76ce529242bd1c8d926ca" have entirely different histories.

3 changed files with 40 additions and 32 deletions

View file

@ -1,6 +1,6 @@
# FolderWeb # FolderWeb
**Just enough, nothing more.** Drop content files in folders, and they become pages. No database, no build process. **Just enough, nothing more.** Drop Markdown files in folders, and they become pages. No database, no build process.
## What is FolderWeb? ## What is FolderWeb?
@ -11,9 +11,8 @@ FolderWeb is a content publishing framework where your file system is your conte
## Key Features ## Key Features
- **File-based routing**: `content/blog/post/``yoursite.com/blog/post/` - **File-based routing**: `content/blog/post/``yoursite.com/blog/post/`
- **Multiple content formats**: Write in Markdown, HTML, or PHP — and mix them freely within the same page. Use Markdown for prose, HTML for structured sections, and PHP when you need dynamic output. Prefix filenames with numbers (`10-intro.md`, `20-gallery.html`) to control render order. - **Multi-language support**: Built-in i18n with URL prefixes
- **Template system**: Override any default template with your own - **Template system**: Override defaults with custom templates
- **Multi-language support**: Built-in i18n with URL prefixes and per-file translations
- **Modern CSS**: CSS variables, nesting, OKLCH colors, grid layouts - **Modern CSS**: CSS variables, nesting, OKLCH colors, grid layouts
- **No build process**: Save and refresh—see changes immediately - **No build process**: Save and refresh—see changes immediately
@ -21,31 +20,29 @@ FolderWeb is a content publishing framework where your file system is your conte
``` ```
project/ project/
├── app/ # Application (never modify) ├── app/ # App (never modify)
├── content/ # Your website content ├── content/ # Your website content
│ ├── front.md # Home page │ ├── front.md # Home page
│ ├── about/ │ ├── about/ # About page
│ │ └── about-me.md │ │ └── about-me.md
│ ├── portfolio/ │ └── blog/ # Blog with list view
│ │ ├── 10-intro.md # Markdown prose │ ├── metadata.ini # Configure template
│ │ ├── 20-gallery.html # HTML layout
│ │ └── 30-stats.php # Dynamic PHP output
│ └── blog/
│ ├── metadata.ini
│ ├── 2025-11-01-first-post/ │ ├── 2025-11-01-first-post/
│ │ ├── first-post.md │ │ ├── first-post.md
│ │ ├── cover.jpg │ │ ├── cover.jpg
│ │ └── metadata.ini │ │ └── metadata.ini
│ └── 2025-11-02-second-post/ │ └── 2025-11-02-second-post/
│ └── post.md │ └── another-post.md
└── custom/ # Your customizations └── custom/ # Your customizations
├── templates/ ├── templates/ # Custom templates
├── styles/ ├── styles/ # Custom CSS
└── config.ini └── config.ini # Configuration
``` ```
## Documentation ## Documentation
Complete documentation available in [`docs/`](docs/). **Complete documentation available in [`docs/`](docs/)**
Start with the **[Getting Started guide](docs/01-getting-started/index.md)** or browse the **[tutorial](docs/02-tutorial/)**. ## Learn More
Start with the **[Getting Started Tutorial](docs/tutorial/00-getting-started.md)** or browse the **[complete documentation](docs/)**.

View file

@ -1,6 +1,19 @@
version: '3.8' version: '3.8'
services: services:
# custom:
# image: php:8.3.12-apache
# container_name: folderweb-custom
# working_dir: /var/www/html/
# volumes:
# - ../app:/var/www/app:z
# - ../content:/var/www/html:z
# - ../custom:/var/www/custom:z
# - ../docs:/var/www/html/docs:z
# - ./apache/custom.conf:/etc/apache2/conf-available/custom.conf:z
# ports:
# - "4040:80"
# command: bash -c "a2enconf custom && a2enmod rewrite && apache2-foreground"
default: default:
build: ./ build: ./
container_name: folderweb-default container_name: folderweb-default

View file

@ -97,21 +97,19 @@ content/
## Multiple Files in One Page ## Multiple Files in One Page
You can combine multiple content files in a single directory. They render as a single page, combined in filename order. You can combine multiple content files in a single directory. They render in **alphabetical order**:
**Prefix filenames with numbers to control the order:**
``` ```
content/portfolio/ content/portfolio/
├── 10-hero.php # Renders first — dynamic PHP banner ├── 00-hero.php # Renders first
├── 20-intro.md # Renders second — Markdown prose ├── 01-intro.md # Renders second
├── 30-gallery.html # Renders third — HTML layout ├── 02-gallery.html # Renders third
└── 40-contact.md # Renders last — Markdown form └── 03-contact.md # Renders last
``` ```
All four files render as one page at `/portfolio/`. You can mix `.md`, `.html`, and `.php` freely — use whichever format fits each section best. All four files render as one page at `/portfolio/`.
**Why number prefixes?** Files are sorted using natural sort (`strnatcmp`), so `10-` comes before `20-` comes before `30-`. Using increments of 10 leaves room to insert new sections later without renaming existing files. Files without a number prefix sort after numbered files. **Use case:** Build pages from modular components—header, content, footer, etc.
## Dates in Folder Names ## Dates in Folder Names
@ -275,13 +273,13 @@ summary = "An introduction to my blog"
``` ```
content/services/ content/services/
├── 10-hero.php ├── 00-hero.php
├── 20-intro.md ├── 01-intro.md
├── 30-pricing.html ├── 02-pricing.html
└── metadata.ini └── metadata.ini
``` ```
All content files render together as one page at `/services/`, in number-prefix order. All files render together as one page at `/services/`.
### Documentation Site ### Documentation Site