Pronto CMS
The CMS that is almost ready ("pronto" in italian) for you to use., (*1)
The aim of Pronto is to be a download and run flat-file based CMS with high speed and low maintenance costs. It uses Laravel Lumen at its core., (*2)
Features
- [x] Markdown content parsing
- [x] Sections and subsections
- [ ] Page and section configurable order
- [x] Multiple level page nesting
- [ ] Multi-language support
- [ ] Themes
- [ ] File Download and assets management
- [x] Imagination
Browser compatibility
At now the plan is to target all the modern browsers (IE10, IE11, Edge, Chrome, Firefox, Safari, Opera latest versions)., (*3)
Requirements
- php 5.5.9+
- php fileinfo extension
- Composer (for managing PHP dependencies)
- NodeJS and NPM (for building the frontend)
Installation
To create a new project use Composer "create-project" command. Pass it the package name (avvertix/pronto
), and the directory to create the project in (e.g. path
). You can also provide a version as third argument, otherwise the latest version is used., (*4)
php composer.phar create-project avvertix/pronto path
Now that all the PHP code is there you could initialize the frontend (i.e. the default theme) by launching, (*5)
npm install
gulp
Content Writing
Your website content will be gathered from the folders and from the Markdown files contained in the storage/content
folder., (*6)
Folders will be converted to sections, while markdown files are the pages. Only markdown file whose extension is .md
will be considered., (*7)
If a folder contains a file named index.md
will be showed when a section is requested., (*8)
We support the following markdown specifications:, (*9)
The framework offers syntax highlighting so please specify the language for each fenced code block., (*10)
Folder naming rules, (*11)
- lower case,
- no spaces,
-
-
and _
for word separation
File naming rules, (*12)
-
.md
extension,
- no spaces,
- use
-
as word separator,
- entirely lower case
Adding images (png, jpg, ...) and resources (pdf, zip, ...), (*13)
Images can be stored in storage/images
and then referenced, in the markdown page, with their names using a special path, like in the example below, (*14)
![alt](./i/image-name.png)
Image file names follow the same rules for file naming as the markdown pages., (*15)
if you want to set a link on an image, you could do that using the following markdown syntax, (*16)
[![](./i/image-name.png)](./i/image-name.png)
The previous example will open the full size version of the image when the image preview is clicked., (*17)
The global navigation menu that will be inserted in the header of the website is entirely made
using a json based configuration. The configuration file, named config.json
, must be inside the storage/app
folder., (*18)
Three types of elements can be inserted in the global navigation:, (*19)
- External links,
- Links to pages,
- Links to sections.
Every element in the menu must have a title
attribute that is used for the UI of the menu and a ref
attribute which holds the link to the element., (*20)
External links, (*21)
For external links you have to specify:, (*22)
-
title
: the title of the link to be showed to the user
-
ref
: the absolute URL
Links to pages, (*23)
For pages you have to specify:, (*24)
-
title
: the title to be showed to the user
-
type
: page
-
ref
: the path of the page, wich consists in the section slug and the page slug (relative to the content
folder)
Links to sections, (*25)
-
title
: the title to be showed to the user
-
type
: section
-
ref
: the path to the section (relative to the content
folder)
The following code block is an example of config.json
menu section., (*26)
{
"menu": [
{
"title": "Git",
"ref": "http://git.project"
},
{
"title": "Sub Section Promoted",
"type": "section",
"ref": "example-section/sub-section-1"
},
{
"title": "Home",
"type": "page",
"ref": "index"
}
]
}
Securing your installation
..., (*27)
Created with Visual Studio Code, (*28)