Refactor: Replace sidebar with horizontal navigation bar
- Remove sidebar and toggle functionality - Add Bootstrap navbar with dropdown menus - Move navigation to top between header and content - Update menu rendering for Bootstrap dropdowns - Clean up unused files (header.mustache, sidebar.mustache, sidebar.js) - Add guide link with book icon in footer - Simplify layout structure - Remove duplicate code and fix syntax errors - Add .gitignore for node_modules and other temp files
This commit is contained in:
171
guide/en.md
Normal file
171
guide/en.md
Normal file
@@ -0,0 +1,171 @@
|
||||
# CodePress CMS Guide
|
||||
|
||||
## Welcome to CodePress CMS
|
||||
|
||||
CodePress is a lightweight, file-based Content Management System built with PHP and Bootstrap.
|
||||
|
||||
### Table of Contents
|
||||
|
||||
1. [Getting Started](#getting-started)
|
||||
2. [Content Management](#content-management)
|
||||
3. [Templates](#templates)
|
||||
4. [Configuration](#configuration)
|
||||
|
||||
---
|
||||
|
||||
## Getting Started
|
||||
|
||||
### Requirements
|
||||
- PHP 8.4+
|
||||
- Web server (Apache/Nginx)
|
||||
- Modern web browser
|
||||
|
||||
### Installation
|
||||
1. Clone or download the CodePress files
|
||||
2. Upload to your web server
|
||||
3. Make sure the `content/` directory is writable
|
||||
4. Navigate to your website in the browser
|
||||
|
||||
### Basic Configuration
|
||||
The most important settings are in `engine/core/config.php`:
|
||||
|
||||
```php
|
||||
$config = [
|
||||
'site_title' => 'My Website',
|
||||
'default_page' => 'home',
|
||||
'content_dir' => __DIR__ . '/../../content',
|
||||
'templates_dir' => __DIR__ . '/../templates'
|
||||
];
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Content Management
|
||||
|
||||
### File Structure
|
||||
```
|
||||
content/
|
||||
├── home.md # Home page
|
||||
├── blog/
|
||||
│ ├── index.md # Blog overview
|
||||
│ ├── article-1.md # Blog article
|
||||
│ └── category/
|
||||
│ └── article.md # Article in category
|
||||
└── about-us/
|
||||
└── info.md # About us page
|
||||
```
|
||||
|
||||
### Content Types
|
||||
CodePress supports three content types:
|
||||
|
||||
#### Markdown (`.md`)
|
||||
```markdown
|
||||
# Page Title
|
||||
|
||||
This is the page content in **Markdown** format.
|
||||
|
||||
## Subsection
|
||||
|
||||
- List item 1
|
||||
- List item 2
|
||||
```
|
||||
|
||||
#### PHP (`.php`)
|
||||
```php
|
||||
<?php
|
||||
$title = "Dynamic Page";
|
||||
?>
|
||||
<h1><?php echo $title; ?></h1>
|
||||
<p>This is dynamic content with PHP.</p>
|
||||
```
|
||||
|
||||
#### HTML (`.html`)
|
||||
```html
|
||||
<h1>HTML Page</h1>
|
||||
<p>This is static HTML content.</p>
|
||||
```
|
||||
|
||||
### Automatic Linking
|
||||
CodePress automatically creates links to other pages when you mention page names in your content.
|
||||
|
||||
---
|
||||
|
||||
## Templates
|
||||
|
||||
### Template Structure
|
||||
CodePress uses Mustache-compatible templates:
|
||||
|
||||
- `layout.mustache` - Main template
|
||||
- `assets/header.mustache` - Header component
|
||||
- `assets/sidebar.mustache` - Sidebar navigation
|
||||
- `assets/footer.mustache` - Footer component
|
||||
|
||||
### Template Variables
|
||||
Available variables in templates:
|
||||
- `{{site_title}}` - Website title
|
||||
- `{{page_title}}` - Current page title
|
||||
- `{{content}}` - Page content
|
||||
- `{{menu}}` - Navigation menu
|
||||
- `{{breadcrumb}}` - Breadcrumb navigation
|
||||
|
||||
---
|
||||
|
||||
## Configuration
|
||||
|
||||
### Basic Settings
|
||||
Edit `engine/core/config.php` for your website:
|
||||
|
||||
```php
|
||||
$config = [
|
||||
'site_title' => 'Your Website Name',
|
||||
'default_page' => 'home', // Default start page
|
||||
'content_dir' => __DIR__ . '/../../content',
|
||||
'templates_dir' => __DIR__ . '/../templates'
|
||||
];
|
||||
```
|
||||
|
||||
### SEO Friendly URLs
|
||||
CodePress automatically generates clean URLs:
|
||||
- `home.md` → `/home`
|
||||
- `blog/article.md` → `/blog/article`
|
||||
|
||||
### Search Functionality
|
||||
The built-in search function searches through:
|
||||
- File names
|
||||
- Content of Markdown/PHP/HTML files
|
||||
|
||||
---
|
||||
|
||||
## Tips and Tricks
|
||||
|
||||
### Page Organization
|
||||
- Use subdirectories for categories
|
||||
- Give each directory an `index.md` for an overview page
|
||||
- Keep file names short and descriptive
|
||||
|
||||
### Content Optimization
|
||||
- Use clear headings (H1, H2, H3)
|
||||
- Add descriptive meta information
|
||||
- Use internal links for better navigation
|
||||
|
||||
### Security
|
||||
- Keep your CodePress installation updated
|
||||
- Restrict write permissions on the `content/` directory
|
||||
- Use HTTPS when possible
|
||||
|
||||
---
|
||||
|
||||
## Support
|
||||
|
||||
### Troubleshooting
|
||||
- **Empty pages**: Check file permissions
|
||||
- **Template errors**: Verify template syntax
|
||||
- **404 errors**: Check file names and paths
|
||||
|
||||
### More Information
|
||||
- Documentation: [CodePress GitHub](https://git.noorlander.info/E.Noorlander/CodePress.git)
|
||||
- Issues and feature requests: GitHub Issues
|
||||
|
||||
---
|
||||
|
||||
*This guide is part of CodePress CMS and is automatically displayed when no content is available.*
|
||||
171
guide/nl.md
Normal file
171
guide/nl.md
Normal file
@@ -0,0 +1,171 @@
|
||||
# CodePress CMS Handleiding
|
||||
|
||||
## Welkom bij CodePress CMS
|
||||
|
||||
CodePress is een lichtgewicht, op bestanden gebaseerd Content Management Systeem gebouwd met PHP en Bootstrap.
|
||||
|
||||
### Inhoudsopgave
|
||||
|
||||
1. [Getting Started](#getting-started)
|
||||
2. [Content Management](#content-management)
|
||||
3. [Templates](#templates)
|
||||
4. [Configuration](#configuration)
|
||||
|
||||
---
|
||||
|
||||
## Getting Started
|
||||
|
||||
### Vereisten
|
||||
- PHP 8.4+
|
||||
- Webserver (Apache/Nginx)
|
||||
- Modern web browser
|
||||
|
||||
### Installatie
|
||||
1. Clone of download de CodePress bestanden
|
||||
2. Upload naar je webserver
|
||||
3. Zorg dat de `content/` map schrijfbaar is
|
||||
4. Navigeer naar je website in de browser
|
||||
|
||||
### Basis Configuratie
|
||||
De belangrijkste instellingen vind je in `engine/core/config.php`:
|
||||
|
||||
```php
|
||||
$config = [
|
||||
'site_title' => 'Mijn Website',
|
||||
'default_page' => 'home',
|
||||
'content_dir' => __DIR__ . '/../../content',
|
||||
'templates_dir' => __DIR__ . '/../templates'
|
||||
];
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Content Management
|
||||
|
||||
### Bestandsstructuur
|
||||
```
|
||||
content/
|
||||
├── home.md # Home pagina
|
||||
├── blog/
|
||||
│ ├── index.md # Blog overzicht
|
||||
│ ├── artikel-1.md # Blog artikel
|
||||
│ └── categorie/
|
||||
│ └── artikel.md # Artikel in categorie
|
||||
└── over-ons/
|
||||
└── info.md # Over ons pagina
|
||||
```
|
||||
|
||||
### Content Types
|
||||
CodePress ondersteunt drie content types:
|
||||
|
||||
#### Markdown (`.md`)
|
||||
```markdown
|
||||
# Pagina Titel
|
||||
|
||||
Dit is de inhoud van de pagina in **Markdown** formaat.
|
||||
|
||||
## Subsectie
|
||||
|
||||
- Lijst item 1
|
||||
- Lijst item 2
|
||||
```
|
||||
|
||||
#### PHP (`.php`)
|
||||
```php
|
||||
<?php
|
||||
$title = "Dynamische Pagina";
|
||||
?>
|
||||
<h1><?php echo $title; ?></h1>
|
||||
<p>Dit is dynamische content met PHP.</p>
|
||||
```
|
||||
|
||||
#### HTML (`.html`)
|
||||
```html
|
||||
<h1>HTML Pagina</h1>
|
||||
<p>Dit is statische HTML content.</p>
|
||||
```
|
||||
|
||||
### Automatische Linking
|
||||
CodePress maakt automatisch links naar andere pagina's wanneer je paginanamen in je content noemt.
|
||||
|
||||
---
|
||||
|
||||
## Templates
|
||||
|
||||
### Template Structuur
|
||||
CodePress gebruikt Mustache-compatible templates:
|
||||
|
||||
- `layout.mustache` - Hoofdtemplate
|
||||
- `assets/header.mustache` - Header component
|
||||
- `assets/sidebar.mustache` - Sidebar navigatie
|
||||
- `assets/footer.mustache` - Footer component
|
||||
|
||||
### Template Variabelen
|
||||
Beschikbare variabelen in templates:
|
||||
- `{{site_title}}` - Website titel
|
||||
- `{{page_title}}` - Huidige pagina titel
|
||||
- `{{content}}` - Pagina inhoud
|
||||
- `{{menu}}` - Navigatie menu
|
||||
- `{{breadcrumb}}` - Broodkruimel navigatie
|
||||
|
||||
---
|
||||
|
||||
## Configuration
|
||||
|
||||
### Basis Instellingen
|
||||
Pas `engine/core/config.php` aan voor jouw website:
|
||||
|
||||
```php
|
||||
$config = [
|
||||
'site_title' => 'Jouw Website Naam',
|
||||
'default_page' => 'home', // Standaard startpagina
|
||||
'content_dir' => __DIR__ . '/../../content',
|
||||
'templates_dir' => __DIR__ . '/../templates'
|
||||
];
|
||||
```
|
||||
|
||||
### SEO Vriendelijke URLs
|
||||
CodePress genereert automatisch schone URLs:
|
||||
- `home.md` → `/home`
|
||||
- `blog/artikel.md` → `/blog/artikel`
|
||||
|
||||
### Zoekfunctionaliteit
|
||||
De ingebouwde zoekfunctie doorzoekt:
|
||||
- Bestandsnamen
|
||||
- Content van Markdown/PHP/HTML bestanden
|
||||
|
||||
---
|
||||
|
||||
## Tips en Tricks
|
||||
|
||||
### Pagina Organisatie
|
||||
- Gebruik submappen voor categoriën
|
||||
- Geef elke map een `index.md` voor een overzichtspagina
|
||||
- Houd bestandsnamen kort en beschrijvend
|
||||
|
||||
### Content Optimalisatie
|
||||
- Gebruik duidelijke koppen (H1, H2, H3)
|
||||
- Voeg beschrijvende meta-informatie toe
|
||||
- Gebruik interne links voor betere navigatie
|
||||
|
||||
### Veiligheid
|
||||
- Houd je CodePress installatie bijgewerkt
|
||||
- Beperk schrijfrechten op de `content/` map
|
||||
- Gebruik HTTPS indien mogelijk
|
||||
|
||||
---
|
||||
|
||||
## Ondersteuning
|
||||
|
||||
### Problemen Oplossen
|
||||
- **Lege pagina's**: Controleer bestandsrechten
|
||||
- **Template fouten**: Verifieer template syntax
|
||||
- **404 fouten**: Controleer bestandsnamen en paden
|
||||
|
||||
### Meer Informatie
|
||||
- Documentatie: [CodePress GitHub](https://git.noorlander.info/E.Noorlander/CodePress.git)
|
||||
- Issues en feature requests: GitHub Issues
|
||||
|
||||
---
|
||||
|
||||
*Deze handleiding is onderdeel van CodePress CMS en wordt automatisch getoond wanneer er geen content beschikbaar is.*
|
||||
Reference in New Issue
Block a user