Mecha is a flat-file content management system for minimalists.

Overview

Mecha CMS

Mecha is a flat-file content management system for minimalists.

Code Size License

Front-End

The default layout uses only Serif and Mono fonts. Different operating systems might display somewhat different results. This preview was taken through a computer with Linux operating system. Serif font that’s displayed in the preview below should be DejaVu Serif:

Front-End

Back-End (Optional)

To be able to activate the back-end feature requires you to install our panel and user extensions. This feature is forever optional. You can choose to use this feature in the local version only, and get rid of it in the public version as the most basic security measure if you want.

Back-End

Colors and font types in the control panel preview above are generated from the default layout files. Without them, the display will look like the preview below:

Back-End

Mecha survives on the principle that a database-less site should be personal, portable, light and easy to be exported and backed up. That’s why most of the projects associated with Mecha are created with personal natures and are dedicated to be used for personal purposes such as blog, journal and diary. Mecha’s market shares are people with high creativity and individuals who want to dedicate themselves to the freedom of speech, that probably don’t have much time to learn web programming languages. By introducing Mecha as files and folders that used to be seen by people everyday in their working desktop, we hope you will soon be familiar with the way Mecha CMS works.

Mecha is as simple as files and folders. Yet, that doesn’t mean that Mecha is weak. Mecha has fairly flexible set of API that you can use without having to make it bloated, keeping you happy focused on developing your own site, according to your personality.

If you want to make something that is super huge with Mecha, that would be possible, but remember that Mecha wasn’t created to replace databases. Mecha was previously created simply to help people getting rid of various resources that are not needed from the start (such as databases). There will be a time when you need a database, and when that time comes, just use a database. Mecha is fairly open to be extended with other database-based applications.

Features

  • Writing pages with ease using Markdown.
  • Unlimited page children.
  • Unlimited page fields.
  • Extensible as hell.
  • Create unique design for each blog post by adding special CSS and JavaScript files using the art extension.
  • Built-in commenting system using the comment extension.
  • RSS and Sitemap using the feed and sitemap extension.
  • Easy to use and well documented API.
  • Almost everything are optional.
  • Control panel extension.

Environments

  • PHP 7.3.0 and above, with enabled mbstring and dom extension.
  • Apache 2.4 and above, with enabled mod_rewrite module.

Preparations

  1. Make sure that you already have the required components.
  2. Download the available package from the home page.
  3. Upload Mecha through your FTP/SFTP to the public folder/directory on your site, then extract it!
  4. Take a look on the available extensions and layouts that you might be interested.
  5. Upload your extension files to .\lot\x and your layout files to .\lot\y. They’re auto-loaded.
  6. Read on how to add pages and tags. Learn on how to create pages from the author by looking at the source code.
  7. Install the panel extension if you are stuck by doing everything manually. You always have the full control to remove this extension without having to worry that your site will stop running after doing so.

Alternatives

Command Line

This assumes that your site’s public directory is in /srv/http. Make sure the folder is empty, or move the existing files to another place first. Don’t forget with that . at the end of the command as written in the example below, to clone the repository into the current root folder.

Using Git

$ cd /srv/http
$ git clone https://github.com/mecha-cms/mecha.git --depth 1 .
$ git submodule update --init --recursive
$ rm .gitmodules composer.json LICENSE README.md
$ rm -r .git

Web Browser

Download the installer file from https://mecha-cms.com/start and then follow the instructions.


Contributors

This project exists and survives because of you. I would like to thank all those who have taken the time to contribute to this project.

Contributors

Contribute financially to keep the project domain and website accessible to everyone. The website provides complete documentation and latest information regarding the software and future development plans. Some parts of the website also serve to provide a clean and efficient project file download feature which is obtained by managing responses from the GitHub API.

Backers

Contribute

Sponsors

0 1 2 3 4 5 6 7 8 9


Release Notes

3.0.0

  • Added class XML.
  • Added functions abort, check, choke, cookie, delete, ip, kick, long, move, save, seal, short, size, status, store, token, type, ua, zone.
  • Changed path state property to route.
  • Implemented WAI-ARIA to allow class-less styling of HTML markup.
  • Improved Genome and Page class to make it possible to inherit (fake) methods and (fake) properties from the parent class automatically.
  • Layout is now behaves like extension. If it does not contain any index.php file, then its entire layout system will be discarded (#157).
  • Moved art and form feature to a separate extension.
  • Moved To::{description,sentence,title} methods to page extension.
  • Moved core extensions and layouts out of the repository and convert them to git sub-modules.
  • Optimized hook sorting mechanism (#156)
  • Re-enabled the layout switcher feature (#205)
  • Refactored function has to make it more useful along with get, let, and set functions.
  • Removed $html option in To::description (previously was To::excerpt). People who want to make page excerpt without HTML should be able to easily remove all the HTML markup from the input first, before using this function.
  • Removed $parent variable (#165)
  • Removed 404.php file requirement for layout.
  • Removed clean, d, i, port property from URL class.
  • Removed get, has, let and set methods from non-static classes (#166)
  • Removed parent method from File, Folder, and Page class.
  • Removed classes Cache, Client, Cookie, Files, Folders, Get, Guard, Path, Post, Request, Route, Server, Session, SGML.
  • Removed constant GROUND, PS.
  • Removed separator options from URL functions and methods (#164)
  • Renamed To::excerpt to To::description.
  • Renamed class Anemon to Anemone.
  • Renamed constant DEBUG to TEST (#159)
  • Renamed constant DS to D.
  • Renamed constant ROOT to PATH.
  • Renamed function anemon to anemone.
  • The e function will no longer evaluate string in the form of JSON pattern (#167)
  • Upgraded PHP version requirement to 7.3.0.

2.6.4

  • Added Path::long() and Path::short() method.
  • Added content-length header to facilitate AJAX-based applications with progress bars.
  • Added link to the core extensions.
  • Added second parameter to the content function to allow user to use this function to create a file.
  • Fixed bug of SGML class when parsing attributes contain Base64 image URL.
  • Fixed bug of default date format not applied to the output (#117)
  • Improved alert message session. Now you can print the $alert variable multiple times and all elements will appear at each location.
  • Improved class auto-loader. \ now will be converted into /, and __ will be converted into . (#96)
  • Improved internal JSON validator.
  • Improved path and URL resolver.
  • Removed function mecha.
  • Renamed $link->active to $link->current in layout navigation.
  • Updated function and method parameter names. Make them to be more semantic for better support with the new named parameter feature in PHP 8.x.
  • Updated the default layout.

2.5.3

  • Bug fixes.

2.5.2

  • Added path helper function.
  • Removed cache optimization stuff from .htaccess. The main .htaccess file should focus only to the rewrite module.
  • Removed all image asset methods.

2.5.1

  • Added YAML\SOH, YAML\ETB, and YAML\EOT constant in the YAML extension (#94)

2.5.0

  • Added $status parameter to Guard::kick() with default value set to 301.
  • Added ? symbol for Route as alias of :key pattern. So, foo/bar/:baz will be equal to foo/bar/?.
  • Added ability to set response status automatically based on the first numeric layout path.
  • Renamed $route->view() method to $route->layout() for consistency.

2.4.0

This update focuses on improving the pagination feature of page extension. $pager->next, $pager->parent and $pager->prev will now return a Page instance or null. This allows us to get richer data easily from the previous and next page property such as to retrieve title, description and image thumbnail to be displayed in the previous and next page navigation HTML.

  • Improved HTML output generated by To::excerpt() method.
  • $pager->next, $pager->parent and $pager->prev are now return a Page instance or null.

2.3.2

  • Added drop helper function.
  • Improved Path methods to allow null values.
  • Updated Parsedown Extra to version 0.8.0.

2.3.1

  • Bug fixes and improvements for the YAML extension.
  • Prefers HTTP/2 header style for both request and response (#89)

2.3.0

This update focuses on improving the token feature so that it is not too strict. We need to give other extension opportunities to load the current page for certain purposes without having to change the current token.

  • Added $deep option for From::HTML() with default value set to false to prevent double encode HTML special characters.
  • Added X-Requested-With header field to fetch() with default value set to CURL to let the client to know that the request is not came from a normal web browser (#86)
  • Fixed double encode on HTML attribute’s value caused by the HTML class (#85)
  • Fixed form extension bug that caused the comment duplicate checker to fails to work.
  • Fixed layout extension bug that does not capture the custom attributes added to the asset path that is relative to the layout folder.
  • Improved alert counter and serializer. Counting alert messages or converting them into a JSON string will not clear the alert session.
  • Improved hook remover. It is now possible to remove a hook function from closures as long as you store the function closure into a variable. You can then remove the hook function using the variable as a reference.
  • Improved HTTP response headers API. They are now case-insensitive.
  • Improved markdown extension. It is now possible to generate HTML
    element automatically from every image that appears alone in a paragraph.
  • Improved token mechanism. Added $for parameter for Guard::token() to set delay time for the token to refresh. The default value is one minute. Previously, every token will be refreshed on every page visits. This causes several obstacles if some extensions require to reload the page to build the cache (even if it is only to load pages in the background) or to prepare it to load the next page via the HTML5 prefetch feature.
  • Removed State::over() method.
  • Removed automatic paragraph tags in page description data for consistency with other page data such as the title data. If I had to be consistent, when the description data is required to be wrapped in paragraph tags, then the title data should also be wrapped in heading tags. But it doesn’t (#87)
  • Renamed Cache::expire() to Cache::stale() for more semantic method naming (#84)
  • Renamed Route::over() to Route::hit() to make it in-line with Cache::hit() (#83)

2.2.2

This update focuses on stabilizing the URL class. In this version, you can use the class to parse all types of URLs, not only internal URLs but also external URLs. Mecha has its own specifications regarding URLs, and is a bit different from the native PHP parse_url function. One of them is the presence of d and i properties. You can learn more about this on the URL reference page.

  • Added optional $d and $i parameter to the URL class constructor.
  • Fixed $lot parameter applied to Route::fire() does not give any effect.

2.2.1

  • Added $as parameter to copy and move methods of File and Folder class.
  • Fixed send function not sending HTML email.
  • Small bug fixes for the let hook.

2.2.0

Compatible with PHP 7.3.0 and above. Mecha uses Closure::fromCallable() method (which is only available in PHP version 7.1.0 and above) to convert named function into closures, so that we can pass $this reference from another class instance to the function body even if it’s a named function. The ?? operator becomes a must-have feature in this version as we no longer use extra $fail parameter on certain class methods to set default values.

  • Added ability to read special file named task.php.
  • Added classes: Client, Files, Folders, Layout, Pager\Page, Pager\Pages, Pages, Post, Server, SGML.
  • Added more static functions: abort, alert, anemon, any, c2f, cache, check, concat, content, cookie, eq, exist, extend, f2c, f2p, fetch, find, fire, ge, get, gt, has, hook, is, kick, le, let, lt, map, mecha, ne, not, open, p2f, page, pages, pluck, route, send, session, set, shake, state, step, stream, test, token.
  • Added page conditional statement features.
  • Moved YAML parser feature to a separate YAML extension.
  • Moved class Page and Pager to a separate Page extension.
  • Moved configuration file from .\lot\extend\:extension\state\config.php to .\lot\x\:extension\state.php.
  • Moved configuration file from .\lot\shield\:layout\state\config.php to .\lot\layout\state.php.
  • Moved configuration file from .\lot\state\config.php to .\state.php.
  • Moved search functionality to a separate Search extension.
  • Now you can call page properties via $this property inside the hook function, either as a named function or as an anonymous function.
  • Removed ability to read special file named __index.php and index__.php. Only index.php file that will be read automatically.
  • Removed automatic constant creation for every folder name in the .\lot directory.
  • Removed classes: Extend Elevator, Form, Mecha, Plugin, Shield, Union.
  • Removed language and layout switcher features. Now we no longer have the ability to change themes through configuration files, and therefore there will only be one theme on every website built with Mecha.
  • Removed plugin feature. There are no such thing called “plugin” in this version. They are now simply called “extension”.
  • Renamed .\lot\extend directory address to .\lot\x.
  • Renamed class Config to State.
  • Renamed class Date to Time.
  • Renamed class Guardian to Guard.
  • Renamed class Message to Alert.
  • Renamed the X constant to P. “P” stands for “Placeholder”.
  • The “Set, Get and Reset” method naming standard has now been changed to “Set, Get and Let”.
  • Use null value everywhere as the default value for all inaccessible data. From now on, use the ?? operator to determine alternative value.
  • $pages variable is now a generator. Every page data in it will be loaded only if you iterate over the generator.

2.0.0

Compatible with PHP 5.3.6 and above.

  • Refactor.
Comments
  • Update to Version 1.2.7 and Install the Category Plugin Makes the Blog Broken

    Update to Version 1.2.7 and Install the Category Plugin Makes the Blog Broken

    Hello developers,

    I noticed the following today and although I have installed the new version. It was an update of the version 1.2.5 to version 1.2.7, and then I installed the categories plugin. Then the blog at http://wpzweinull.ch/cms/mecha was no longer accessible.

    I now had to return the Version 1.2.5 and use without the plugin categories.

    It was in a browser http error, but unfortunately I had no Error Logs and do not know what was the reason.

    In your Developer Blog Mecha-cms.com I can already see the categories and the new version. For me it makes the blog broken, for whatever reason ;(

    I do not know if you can help without more information to me. I'll leave it for the first time in the version 1.2.5.

    I wanted to tell.

    Thanks in advance.

    paramedic 
    opened by ghost 9
  • Nginx Configuration Example

    Nginx Configuration Example

    I could not find an Nginx configuration example so I used the following.

    server {
        listen       80;
        server_name  mecha.local;
        access_log  /home/example/web/mecha/access-logs/access.log;
        error_log /home/example/web/mecha/access-logs/error.log;
        root /home/peter/example/mecha/public_html;
        index  index.php;
    
        location / {
            try_files $uri $uri/ @rewrite;
        }
        
        # Include PHP 7 config.
        include /home/example/web/nginx.php7.conf;
        
        location @rewrite {
            rewrite ^/(.*)$ /index.php?_=$1? last;
        }
    
    }
    
    improvement 
    opened by petermoo 6
  • Exclude Page from Menu+Page Count

    Exclude Page from Menu+Page Count

    hello,

    how can i exclude a page from the menu/nav? i looked at reference but can´t figure it out.

    also how can i count the total pages from article (the total pages from one page) and echo it.

    thank you in advanced.

    have a nice day ttrack

    question 2.x.x x.page x.panel 
    opened by ttrack 5
  • I wish the Reactions plugin also with Mecha v1 CMS - :)

    I wish the Reactions plugin also with Mecha v1 CMS - :)

    Hi @tovic ,

    I like to work with both Mecha CMS versions and with Mecha v1, I just asked myself whether it would not be possible to provide the new Reactions plugin for it.

    Did you play with this idea or will not you do anything in this regard?

    Reactions plugin I find simply cool and some blog readers just express their mood. I do not mind if there are a few negative reactions. So I know at least that the blog reader was angry or something in the article did not fit.

    Then I wait for your feedback. Thanks in advance.

    opened by ghost 5
  • Less Folder Structure Maybe?

    Less Folder Structure Maybe?

    .\engine\
    ├── use\ 👎
    │   ├── anemone.php
    │   ├── file.php
    │   ├── folder.php
    │   ├── from.php
    │   ├── genome.php
    │   ├── hook.php
    │   ├── is.php
    │   ├── state.php
    │   ├── time.php
    │   ├── to.php
    │   └── u-r-l.php
    └── use.php 👎
    

    Rationales

    1. Using use as the folder name to store classes because of the native PHP syntax for importing classes (and functions, and constants). 👎

      namespace Foo\Bar;
      use Baz, Qux;
      
    2. Using use as the folder name to store classes because of the use property used to list the dependencies of an extension or a layout as written in the about.page file 👎. This practice was last performed and maintained until Mecha version 2.6.4:

      ---
      title: Comment
      description: Built-in commenting system.
      version: 1.0.0
      use:
        '.\lot\x\alert': 1
        '.\lot\x\asset': 1
        '.\lot\x\form': 0
        '.\lot\x\page': 1
      ...
      
      Lorem ipsum dolor sit amet.
      
    3. Renaming Anemon class to Anemone or simply rename it to another term if it is too long because when I search for it, the correct result is always directed to anemone.

      Screenshot 2021-11-15 at 20-39-27 ANEMON Synonyms Antonyms Thesaurus com

    4. Removing Cookie, Get, Post, Request, Server and Session class. It is better to optimize the automatic value evaluation from the first time the request is made. Using native $_GET and $_POST variable is not that bad. You can still use the function get(), let() and set() if you like the dot notation syntax.

      https://github.com/mecha-cms/mecha/blob/v2.6.4/engine/fire.php#L24-L45

      Working with cookies is still quite difficult, because determining the expiration time on cookies is not user friendly. It is also not possible to store cookie data other than as strings, except with the help of functions to encode data from/to strings. So a helper function may still be needed:

      if ('POST' === $_SERVER['REQUEST_METHOD'] && 0 === get($_POST, 'foo.bar')) {
          cookie('foo', [1, 2, 3], '1 week');
      }
      
    5. Removing Files class, to get rid of the assumption that this class is an optimizer for the global variable $_FILES, as Get class was for optimizing $_GET and Post class was for optimizing $_POST.

    6. Removing Folders class. This class is useless.

    7. Removing Guard class.

    8. Removing Lot class.

    9. Removing Route class.

    10. Removing Cache class. Might be more suitable as an extension.

    11. Removing Client class.

    12. Moving HTML and SGML class to layout extension.

    13. Removing Path class. This class is like a group of static functions hosted under namespace Path. Useless. There are better functions, including the native ones:

      • Path::B($path)basename($path)
      • Path::D($path, 2)dirname($path, 2) … FYI, PHP already support directory traversal with configurable levels.
      • Path::F($path)dirname($path) . DS . pathinfo($path, PATHINFO_FILENAME)
      • Path::N($path)basename($path, '.txt')
      • Path::R($path, ROOT)strtr($path, [ROOT . DS => ""])
      • Path::X($path)pathinfo($path, PATHINFO_EXTENSION)
    diet 
    opened by taufik-nurrohman 4
  • Remove CRUD Utility from `File` and `Folder` Class

    Remove CRUD Utility from `File` and `Folder` Class

    File class and its derivative classes such as Page, Tag and User should be read-only. This also includes the Folder class.

    I realized that native PHP functions aren’t that bad. Adding and removing files/folders using native PHP functions should increase the performance.

    file_get_contents() and file_put_contents() are quite common. Even, we have the short function equivalent named content(). The content() function should be enough to do a quick CRUD task. The missing functions in my opinion are:

    • File::exist() and Folder::exist() may be replaced by the exist() function.
    • touch() with adaptive mode input (e.g. can accept octal number in string format captured from form data). This can be replaced with a new function, probably I will give a name to it poke() or seal().
    • unlink() that can remove folder with its contents. This should be replaced with a new function. But I don’t have any idea about the function name for this kind of task. As I know, delete keyword is not reserved in PHP, and there is no PHP function named delete(). But I am still not sure. This name is too generic that probably, in the future, PHP would propose a native function named delete() anyway.
    diet 
    opened by taufik-nurrohman 4
  • Error: Invalid Token

    Error: Invalid Token

    • Unzipped the repo to a subdirectory on my dev server.
    • Went to dev.server.com/subdirectory/install.php
    • Entered:
    • Submit ...
    • Response: Invalid Token.

    This is not a terribly informative error, and I'm pretty sure this isn't what is supposed to happen while installing.

    Screenshot: invalid-token-error

    choked 
    opened by e-n-l 4
  • Cannot Insert HTML Code into a Post?

    Cannot Insert HTML Code into a Post?

    hi. here i installed the app:http://as3.brite.biz/mecha-cms ,but after i insert html code into a post and publish it,the post http://as3.brite.biz/mecha-cms/article/jingle-bell cannot be shown normally. how to fix it? tks

    question 
    opened by luckypoem 4
  • Cannot Upload a Featured Image

    Cannot Upload a Featured Image

    Hi Taufik, I cannot upload a featured image to one page. It's persist old error from the panel and I cannot save the image. Can you test and check this itself?

    Thanks in Advance!

    opened by AlexL777 3
  • Pagination Specification for Version 2.2.2

    Pagination Specification for Version 2.2.2

    Generic Pages’ URL Path

    • http://127.0.0.1/blog

    Pages’ URL Path (Paginated)

    • http://127.0.0.1/blog/2

    Generic Page’s URL Path

    • http://127.0.0.1/blog/foo-bar

    Tags’ Page (Always Paginated)

    • http://127.0.0.1/blog/tag/foo-bar

    Tags’ Page (Paginated)

    • http://127.0.0.1/blog/tag/foo-bar/2

    Next Extension (Paginated)

    • http://127.0.0.1/blog/foo-bar/page/2

    Comment Extension (Paginated)

    • http://127.0.0.1/blog/foo-bar/comment/2

    Pattern

    path/key(/value)?(/offset)?
    
    • path → URL path that maps to a page that exists.
    • key → Context which has a default value set to true; example: /article/foo-bar/comment/1 would be extracted to something like ["article/foo-bar","comment=true",1]
    • key/value → Context which has a value set to value; example: /article/tag/foo/1 would be extracted to something like ["article","tag=foo",1]

    Route

    • */:i, *
    • */comment/:i, */comment
    • */tag/:name/:i, */tag/:name

    ~~TODO~~

    • Remove $url->i property.

      This URL part should be in the $url->path so that it becomes standard and so any URL string could be parsed easily with parse_url() function without extra process to extract the page offset from URL path.

    • Remove $url->d property.

      Maybe we could determine context to the URL constructor so that we could set custom base URL based on place where Mecha was installed:

      $r = 'http://127.0.0.1/mecha/foo/bar/2';
      $url = new URL($r, '/mecha');
      
      echo $url; // `http://127.0.0.1/mecha`
      echo $url->path; // `/foo/bar/2`
      
    diet 
    opened by taufik-nurrohman 3
  • How can I display Post Thumbnails on Mecha v1

    How can I display Post Thumbnails on Mecha v1

    I would like to know if it is possible to display blogpost pictures on the blog homepage in the teaser? With Mecha v2 works so something and with v1?

    I would then work with pictures in the blog posts in the editor and the first picture should then be displayed in the Article-Teaser in the Frontend.

    How can I achieve this?

    Thanks in advance.

    opened by ghost 3
Releases(v3.0.0)
  • v3.0.0(Oct 26, 2022)

    • [x] #233 Added $deep option to HTML and XML class constructor to parse elements recursively without the help of DOMDocument class.
    • [x] Added class XML.
    • [x] Added functions abort, check, choke, cookie, delete, ip, kick, long, move, save, seal, short, size, status, store, token, type, ua, zone.
    • [x] Changed path state property to route.
    • [x] Implemented WAI-ARIA to allow class-less styling of HTML markup.
    • [ ] Improved z function to properly export object in the form of stdClass, Closure and any class instances.
    • [x] Improved Genome and Page class to make it possible to inherit (fake) methods and (fake) properties from the parent class automatically.
    • [x] #157 Layout is now behaves like extension. If it does not contain any index.php file, then its entire layout system will be discarded.
    • [x] Moved alert, art and form feature to a separate extension.
    • [x] Moved To::{description,sentence,title} methods to page extension.
    • [x] Moved core extensions and layouts out of the repository and convert them into git sub-modules.
    • [x] #156 Optimized hook sorting mechanism.
    • [x] #205 Re-enabled the layout switcher feature.
    • [x] Refactored function has to make it more useful along with get, let, and set functions.
    • [x] Removed $html option in To::description (previously was To::excerpt). People who want to make page excerpt without HTML should be able to easily remove all the HTML markup from the input first, before using this function.
    • [x] #165 Removed $parent variable, but added parent property for $page.
    • [x] Removed 404.php file requirement for layout.
    • [x] Removed clean, d, i, port property from URL class.
    • [x] #166 Removed get, has, let and set methods from non-static classes.
    • [x] #1 Removed pagination for single page.
    • [x] Removed classes Cache, Client, Cookie, Files, Folders, Get, Guard, Path, Post, Request, Route, Server, Session, SGML.
    • [x] Removed constant GROUND, PS.
    • [x] #164 Removed separator options from URL functions and methods.
    • [x] Renamed To::dec and To::hex to To::entity.
    • [x] Renamed From::dec and From::hex to From::entity.
    • [x] Renamed To::excerpt to To::description.
    • [x] Renamed class Anemon to Anemone.
    • [x] #159 Renamed constant DEBUG to TEST.
    • [x] Renamed constant DS to D.
    • [x] Renamed constant ROOT to PATH.
    • [x] Renamed function anemon to anemone.
    • [x] Standardized PHP $_POST data that was merged from $_FILES data which now contains from (in place of full_path), name, path (in place of tmp_name), size, status (in place of error) and type properties.
    • [x] #167 The e function will no longer evaluate string in the form of JSON pattern.
    • [x] Upgraded PHP version requirement to 7.3.0.
    • [x] Added $preserve option to To::{file,folder}() method.
    • [x] Allowed Time class instance without parameters.
    • [x] Loaded extensions and layouts in try/catch block for safety.
    Source code(tar.gz)
    Source code(zip)
  • v2.6.4(Nov 13, 2021)

    • Added Path::long() and Path::short() method.
    • Added content-length header to facilitate AJAX-based applications with progress bars.
    • Added link to the core extensions.
    • Added second parameter to the content function to allow user to use this function to create a file.
    • Fixed bug of SGML class when parsing attributes contain Base64 image URL.
    • #117 Fixed bug of default date format not applied to the output.
    • Improved alert message session. Now you can print the $alert variable multiple times and all <alert> elements will appear at each location.
    • #96 Improved class auto-loader. \ now will be converted into /, and __ will be converted into .
    • Improved internal JSON validator.
    • Improved path and URL resolver.
    • Removed function mecha.
    • Renamed $link->active to $link->current in layout navigation.
    • Updated function and method parameter names. Make them to be more semantic for better support with the new named parameter feature in PHP 8.x.
    • Updated the default layout.
    Source code(tar.gz)
    Source code(zip)
  • v2.5.2(Jan 30, 2021)

    • Added path helper function.
    • Removed cache optimization stuff from .htaccess. The main .htaccess file should focus only to the rewrite module.
    • Removed all image asset methods.
    Source code(tar.gz)
    Source code(zip)
  • v2.5.1(Nov 22, 2020)

  • v2.5.0(Sep 13, 2020)

    • Added $status parameter to Guard::kick() with default value set to 301.
    • Added ? symbol for Route as alias of :key pattern. So, foo/bar/:baz will be equal to foo/bar/?.
    • Added ability to set response status automatically based on the first numeric layout path.
    • Renamed $route->view() method to $route->layout() for consistency.
    Source code(tar.gz)
    Source code(zip)
  • v2.4.0(Jul 13, 2020)

    This update focuses on improving the pagination feature of page extension. $pager->next, $pager->parent and $pager->prev will now return a Page instance or null. This allows us to get richer data easily from the previous and next page property such as to retrieve title, description and image thumbnail to be displayed in the previous and next page navigation HTML.

    • Improved HTML output generated by To::excerpt() method.
    • $pager->next, $pager->parent and $pager->prev are now return a Page instance or null.
    Source code(tar.gz)
    Source code(zip)
  • v2.3.2(Jun 21, 2020)

  • v2.3.1(Jun 19, 2020)

  • v2.3.0(Jun 13, 2020)

    This update focuses on improving the token feature so that it is not too strict. We need to give other extension opportunities to load the current page for certain purposes without having to change the current token.

    • Added $deep option for From::HTML() with default value set to false to prevent double encode HTML special characters.
    • #86 Added X-Requested-With header field to fetch() with default value set to CURL to let the client to know that the request is not came from a normal web browser.
    • #85 Fixed double encode on HTML attribute’s value caused by the HTML class.
    • Fixed form extension bug that caused the comment duplicate checker to fails to work.
    • Fixed layout extension bug that does not capture the custom attributes added to the asset path that is relative to the layout folder.
    • Improved alert counter and serializer. Counting alert messages or converting them into a JSON string will not clear the alert session.
    • Improved hook remover. It is now possible to remove a hook function from closures as long as you store the function closure into a variable. You can then remove the hook function using the variable as a reference.
    • Improved HTTP response headers API. They are now case-insensitive.
    • Improved markdown extension. It is now possible to generate HTML <figure> element automatically from every image that appears alone in a paragraph.
    • Improved token mechanism. Added $for parameter for Guard::token() to set delay time for the token to refresh. The default value is one minute. Previously, every token will be refreshed on every page visits. This causes several obstacles if some extensions require to reload the page to build the cache (even if it is only to load pages in the background) or to prepare it to load the next page via the HTML5 prefetch feature.
    • Removed State::over() method.
    • #87 Removed automatic paragraph tags in page description data for consistency with other page data such as the title data. If I had to be consistent, when the description data is required to be wrapped in paragraph tags, then the title data should also be wrapped in heading tags. But it doesn’t.
    • #84 Renamed Cache::expire() to Cache::stale() for more semantic method naming.
    • #83 Renamed Route::over() to Route::hit() to make it in-line with Cache::hit().
    Source code(tar.gz)
    Source code(zip)
  • v2.2.2(Mar 14, 2020)

    This update focuses on stabilizing the URL class. In this version, you can use the class to parse all types of URLs, not only internal URLs but also external URLs. Mecha has its own specifications regarding URLs, and is a bit different from the native PHP parse_url function. One of them is the presence of d and i properties. You can learn more about this on the URL reference page.

    • Added optional $d and $i parameter to the URL class constructor.
    • Fixed $lot parameter applied to Route::fire() does not give any effect.
    Source code(tar.gz)
    Source code(zip)
  • v2.2.1(Feb 28, 2020)

    • Added $as parameter to copy and move methods of File and Folder class.
    • Fixed send function not sending HTML email.
    • Small bug fixes for the let hook.
    Source code(tar.gz)
    Source code(zip)
  • v2.2.0(Jan 16, 2020)

    Compatible with PHP 7.3.0 and above. Mecha uses Closure::fromCallable() method (which is only available in PHP version 7.1.0 and above) to convert named function into closures, so that we can pass $this reference from another class instance to the function body even if it’s a named function. The ?? operator becomes a must-have feature in this version as we no longer use extra $fail parameter on certain class methods to set default values.

    • Added ability to read special file named task.php.
    • Added classes: Client, Files, Folders, Layout, Pager\Page, Pager\Pages, Pages, Post, Server, SGML.
    • Added more static functions: abort, alert, anemon, any, c2f, cache, check, concat, content, cookie, eq, exist, extend, f2c, f2p, fetch, find, fire, ge, get, gt, has, hook, is, kick, le, let, lt, map, mecha, ne, not, open, p2f, page, pages, pluck, route, send, session, set, shake, state, step, stream, test, token.
    • Added page conditional statement features.
    • Moved YAML parser feature to a separate YAML extension.
    • Moved class Page and Pager to a separate Page extension.
    • Moved configuration file from .\lot\extend\:extension\state\config.php to .\lot\x\:extension\state.php.
    • Moved configuration file from .\lot\shield\:layout\state\config.php to .\lot\layout\state.php.
    • Moved configuration file from .\lot\state\config.php to .\state.php.
    • Moved search functionality to a separate Search extension.
    • Now you can call page properties via $this property inside the hook function, either as a named function or as an anonymous function.
    • Removed ability to read special file named __index.php and index__.php. Only index.php file that will be read automatically.
    • Removed automatic constant creation for every folder name in the .\lot directory.
    • Removed classes: Extend Elevator, Form, Mecha, Plugin, Shield, Union.
    • Removed language and layout switcher features. Now we no longer have the ability to change themes through configuration files, and therefore there will only be one theme on every website built with Mecha.
    • Removed plugin feature. There are no such thing called “plugin” in this version. They are now simply called “extension”.
    • Renamed .\lot\extend directory address to .\lot\x.
    • Renamed class Config to State.
    • Renamed class Date to Time.
    • Renamed class Guardian to Guard.
    • Renamed class Message to Alert.
    • Renamed the X constant to P. “P” stands for “Placeholder”.
    • The “Set, Get and Reset” method naming standard has now been changed to “Set, Get and Let”.
    • Use null value everywhere as the default value for all inaccessible data. From now on, use the ?? operator to determine alternative value.
    • $pages variable is now a generator. Every page data in it will be loaded only if you iterate over the generator.
    Source code(tar.gz)
    Source code(zip)
  • v2.0.0(Jan 16, 2018)

  • v1.2.8(Jan 14, 2017)

  • v1.2.7(Jul 14, 2016)

    Highlight

    Added options Field Type

    Just like option field type, but users can select more than one option with this field type. Field type aliases like t for text, s for summary and b for boolean are now completely removed because of that option and options field type which have the same o prefix.

    Added attributes and parser Property for Field

    Make it possible to set custom HTML attributes in custom fields, and also to set custom function to validate user input on data submission.

    http://mecha-cms.com/article/version-1-2-7

    Source code(tar.gz)
    Source code(zip)
  • v1.2.6(May 22, 2016)

    Highlight

    Internal Hook Updates

    My first plan on the renewal of this CMS was to provide a better support for the category plugin by updating the data carried along with the hooks to be more stable.

    Advance Markdown Attribute Parser

    I recently updated the custom attributes parser in my Parsedown Extra extension. You can now add more HTML attributes other than ID and classes on every Markdown syntax that can accept custom attributes such as code block, heading, image and link using normal HTML attributes syntax.

    Source code(tar.gz)
    Source code(zip)
  • v1.2.5(Apr 30, 2016)

    • Unblacklisting the hard-coded page slug

    • Improve page type checking

    • Reorder parameter in most Get method to parse the page file:

      Get::post($reference, $excludes, $folder, $FP, $connector);
      Get::response($reference, $excludes, array $folder, array $FP, $connector);
      
    Source code(tar.gz)
    Source code(zip)
  • v1.2.4(Apr 19, 2016)

  • v1.2.3(Mar 27, 2016)

    http://mecha-cms.com/article/version-1-2-3

    • Switch to Parsedown Extra
    • Add ability to create recent and random posts by tag, time and slug
    • Layout updates (grid system)
    • Allow nested query string array from $_GET to be parsed by HTTP::query()
    • Fix inconsistent HTML parser toggle view
    • HTML parser toggle will be replaced by a select box contains list of the available HTML parser if we have more than 1 HTML parser engine
    • Etc.
    Source code(tar.gz)
    Source code(zip)
  • v1.2.2(Feb 26, 2016)

  • v1.2.1(Feb 21, 2016)

  • v1.2.0(Feb 8, 2016)

    v1.2.0-alpha.5

    • Fix missing filter for field item https://github.com/mecha-cms/mecha-cms/commit/8c6ea84e765cd854b3f839916319edf6c68af99b
    • Allow user to use relative URL protocol in external asset URL https://github.com/mecha-cms/mecha-cms/commit/527b011479951cf2286191c2f793f43f1ed2788f
    • Allow to select comment without parent ID with Get::comments('DESC', 'parent:null') https://github.com/mecha-cms/mecha-cms/commit/25de290eabfa674ccccc4aa81df35ec9b9f0a79f
    • Allow plugin configurator without form element, auto-detected + add default plugin configuration route for faster plugin development https://github.com/mecha-cms/mecha-cms/commit/ece5a278f49a635d51989d2de75efe41bbcdab65
    • Possible to add configuration data in shield manager https://github.com/mecha-cms/mecha-cms/commit/0c255f48a4a20b140ea81725ad84a70ddefb844b
    • Etc, bug fix.

    v1.2.0-alpha.4

    • Fix comment form submission bug.

    v1.2.0-alpha.3

    • Do not use label element as the content field wrapper to prevent invalid HTML + focusable area bug if we add custom text editors in it which usually will use form element such as button and input as toolbar controls https://github.com/mecha-cms/mecha-cms/commit/ad984caad7e07feea7156f7fcc040f74ac07f1a6
    • Include ID information in Shield::info() and Plugin::info(), if folder does not exist, return id: false https://github.com/mecha-cms/mecha-cms/commit/b6b9b13888e789f2864e827345491d05ad41fe92
    • Fix folder rename bug https://github.com/mecha-cms/mecha-cms/commit/4dc810f7d9d3dbdac8f8afc32818d901612a82a1
    • Others https://github.com/mecha-cms/mecha-cms/commit/963f7fd39d480fb66be8d36c2a74c1a3379aa91c https://github.com/mecha-cms/mecha-cms/commit/57df46c956aae028b2f1332de927545dbe9c0bf6

    v1.2.0-alpha.2

    • Fix: backend assets still visible by visitors even if you are not logged in.

    v1.2.0-alpha

    • http://mecha-cms.com/article/version-1-2-0
    • Fixed some XSS issue reported by Tim Coen (thanks a lot)
    Source code(tar.gz)
    Source code(zip)
  • v1.1.6(Oct 23, 2015)

    Bug fixes:

    • Fix broken backup manager https://github.com/mecha-cms/mecha-cms/commit/24f455a600b95c13362bde176b76a3aa59b9bd2d
    • Fix RSS feed error https://github.com/mecha-cms/mecha-cms/commit/ee73bad32546aa45da8a39e5a20852a947d997c1
    Source code(tar.gz)
    Source code(zip)
  • v1.1.5(Oct 14, 2015)

  • v1.1.4(Oct 14, 2015)

    • Various CSS and languages updates https://github.com/mecha-cms/mecha-cms/commit/032b24c94957f5565778e99cfda9db49a5e3ef4f https://github.com/mecha-cms/mecha-cms/commit/584f118749a3fb458059b8d4ce47bc3e54d5ec4d https://github.com/mecha-cms/mecha-cms/commit/8dcc65d70aa798d637c6132f8b3a637696b752d9
    • Do not include ROOT path in plugins.order.cache file https://github.com/mecha-cms/mecha-cms/commit/a7332890a2d7b7ec85947287f73f6a1eaffdf45f
    • Allow custom page offset placement in the generated pagination data with a wildcard https://github.com/mecha-cms/mecha-cms/commit/5f8114eefa89e8a1825020a38b729454fe0bc14a
    • Update MTE and HTE plugin https://github.com/mecha-cms/mecha-cms/commit/a8edb42bcc7bfc9646c3f74466e9c800329dbddc
    • Add more helper methods for the File class https://github.com/mecha-cms/mecha-cms/commit/6e4ebb45997b298c9ab9ca8d25885ebd5051236d
    • Add new custom fields type: file, composer and editor https://github.com/mecha-cms/mecha-cms/commit/b46c07309ad3f2acc966d52474d509a3603a083b https://github.com/mecha-cms/mecha-cms/commit/b6ff9c7042661104061a3d2033624e9d88ed7695
    • Redirect to the previous URL on re-login if possible https://github.com/mecha-cms/mecha-cms/commit/85955a0983ca49a90c08f7a201185688adecd9d6
    • Move shell, sword and object folders to assets folder https://github.com/mecha-cms/mecha-cms/commit/da428866637e8bec7d9c4a87869d4a5613458f53 https://github.com/mecha-cms/mecha-cms/commit/33cca0415dc29575945615ba3f554b4be1af0aff https://github.com/mecha-cms/mecha-cms/commit/7f4a22988d79aa8ccda39491ca0be2266d68b27b
    • Allow custom login redirection URL with query string ?kick=%URL% https://github.com/mecha-cms/mecha-cms/commit/dc2aec951dcb5d4eaf0e5195f87e4ea34c3e3a4d
    • Allow dynamic custom built-in shortcodes https://github.com/mecha-cms/mecha-cms/commit/c895fb863d922106537e6647db1e0898257b3710
    • Add more wildcard option for the built-in shortcodes https://github.com/mecha-cms/mecha-cms/commit/d0cd0f50c70cd2328f3cce8ae489f180a2ff195d
    • Auto-center the image captcha https://github.com/mecha-cms/mecha-cms/commit/bf55217abce09543975b19b14038931fc0c5ce65
    • Create a more-compact custom field data https://github.com/mecha-cms/mecha-cms/commit/fa4e41cd3193458c79637fdeed38f1d8bfc644cd
    • Add helper functions for JavaScript https://github.com/mecha-cms/mecha-cms/commit/68e470cf31afdd478d91eb23564675bec49c7294 https://github.com/mecha-cms/mecha-cms/commit/b0605fafe8e68231ad48c6b8a40fca43be3389ae
    • Add description and placeholder field for custom fields https://github.com/mecha-cms/mecha-cms/commit/bbf6d20499eecfba29ac0d0495e6260bf47a5458 https://github.com/mecha-cms/mecha-cms/commit/b6240dc6ca80f4eed8dcb837d2d0f01431ba5e98
    • Allow option group in Form::select() https://github.com/mecha-cms/mecha-cms/commit/7edc3c4244d2936de2f0f664c58c11674f2a572f
    • Add Widget::manager('BAR') https://github.com/mecha-cms/mecha-cms/commit/0ed2229a87829e49594920cfcbba4f7455abe2af
    • Allow nested list item with Cell::ol() and Cell::ul() https://github.com/mecha-cms/mecha-cms/commit/f2644fbb205174edd7eeef44ed5f9bb7faa7ba48
    • Allow toggle in tab and accordion widget https://github.com/mecha-cms/mecha-cms/commit/7ccd98c06d51e8a0a86bef8626b2c942580375c8
    • Collect all attached MTE element, replace all on_control_* hook name to on_(composer|editor)_* for consistency https://github.com/mecha-cms/mecha-cms/commit/8cc3dbf9f5070dd9e75cb87c995bc1db76b4eb47
    • Add missing hooks for sortable item by dragging https://github.com/mecha-cms/mecha-cms/commit/8492dd529f5c0dcd20d84e6914f641f22c3e8087
    • Add more backend hooks https://github.com/mecha-cms/mecha-cms/commit/b37838624b9108c86e0157cafa9ca36f571ab1b5
    • Automatically show donate button for Mecha CMS by adding a <!-- block:donate --> in the about.txt file https://github.com/mecha-cms/mecha-cms/commit/e2e105d9e307e776f0999090818c0a42f3f6272a https://github.com/mecha-cms/mecha-cms/commit/a648867a397298ef42f844f69642d93761338c3c
    • Allow Shield::info() and Plugin::info() to output the results as array with the second parameter https://github.com/mecha-cms/mecha-cms/commit/0a152f346f3ca840a74d1743714e2248453f36c3
    • Update Font Awesome version to 4.4.0 https://github.com/mecha-cms/mecha-cms/commit/39e7c4eae223c4e33adb1e7ac8300f911ef4f479
    • Use atom.css specifically to handle the typographic things https://github.com/mecha-cms/mecha-cms/commit/6f5fc3c826dcfce657e6e0dfe7e43146711a548f
    • Better image URL extractor https://github.com/mecha-cms/mecha-cms/commit/87c5f49dab61dadf5265a8e5467db847f2157e3a
    • Add $pager->step->url->first and $pager->step->url->last https://github.com/mecha-cms/mecha-cms/commit/a70ebc1d623e138d034c2e8539970bf229da532d
    • Fix Guardian::memorize() limitation https://github.com/mecha-cms/mecha-cms/commit/0c9acce339a6327d61671ed47b14caf83194aaa2
    • Allow for creating custom comment constructor by adding a PHP file named as task.comment.php in the cabinet\shields\your-current-shield-folder\workers folder https://github.com/mecha-cms/mecha-cms/commit/1e1935f974ae808c04c983f9a74fefd7df280b0a
    Source code(tar.gz)
    Source code(zip)
Owner
Mecha
Mecha is a free PHP flat-file content management system for minimalists.
Mecha
NukeViet 132 Nov 27, 2022
Modern, Crazy Fast, Ridiculously Easy and Amazingly Powerful Flat-File CMS

Grav Grav is a Fast, Simple, and Flexible, file-based Web-platform. There is Zero installation required. Just extract the ZIP archive, and you are alr

Grav 13.6k Jan 4, 2023
FlatPress is a lightweight, easy-to-set-up flat-file blogging engine.

[flatpress.org] [Support forum] [Wiki] [GitHub] [Mastodon] [Twitter] [Changelog] [Contributors] Welcome to FlatPress! FlatPress is a lightweight, easy

FlatPress 143 Dec 22, 2022
Pico is a stupidly simple, blazing fast, flat file CMS.

Pico Pico is a stupidly simple, blazing fast, flat file CMS. Visit us at http://picocms.org/ and see http://picocms.org/about/ for more info. Screensh

null 3.6k Jan 5, 2023
HTMLy is an open source Databaseless Blogging Platform or Flat-File Blog prioritizes simplicity and speed written in PHP

HTMLy is an open source Databaseless Blogging Platform or Flat-File Blog prioritizes simplicity and speed written in PHP. HTMLy can be referred to as Flat-File CMS either since it will also manage your content.

Dan 858 Jan 6, 2023
Pico is a stupidly simple, blazing fast, flat file CMS.

Pico is a stupidly simple, blazing fast, flat file CMS.

null 3.6k Jan 5, 2023
Pico is a stupidly simple, blazing fast, flat file CMS.

Pico is a stupidly simple, blazing fast, flat file CMS.

null 15 Jul 30, 2022
Herbie is a simple Flat-File CMS- und Blogsystem based on human readable text files

Herbie is a simple Flat-File CMS- und Blogsystem based on human readable text files

HERBIE 63 Nov 13, 2022
True Multisite, Modern, Crazy Fast, Ridiculously Easy and Amazingly Powerful Flat-File CMS powered by PHP, Markdown, Twig, and Symfony

True Multisite, Modern, Crazy Fast, Ridiculously Easy and Amazingly Powerful Flat-File CMS powered by PHP, Markdown, Twig, and Symfony

null 4 Oct 28, 2022
The repository for Coaster CMS (coastercms.org), a full featured, Laravel based Content Management System

The repository for Coaster CMS (coastercms.org) a Laravel based Content Management System with advanced features and Physical Web integration. Table o

Coaster CMS 392 Dec 23, 2022
Core framework that implements the functionality of the Sulu content management system

Sulu is a highly extensible open-source PHP content management system based on the Symfony framework. Sulu is developed to deliver robust multi-lingua

Sulu CMS 921 Dec 28, 2022
Fully CMS - Multi Language Content Management System - Laravel

Fully CMS Laravel 5.1 Content Managment System not stable! Features Laravel 5.1 Bootstrap Authentication Sentinel Ckeditor Bootstrap Code Prettify Fil

Sefa Karagöz 479 Dec 22, 2022
Flextype is an open-source Hybrid Content Management System with the freedom of a headless CMS and with the full functionality of a traditional CMS

Flextype is an open-source Hybrid Content Management System with the freedom of a headless CMS and with the full functionality of a traditional CMS. Building this Content Management System, we focused on simplicity. To achieve this, we implemented a simple but powerful API's.

Flextype 524 Dec 30, 2022
Soosyze CMS is a minimalist content management system in PHP, without database to create and manage your website easily

Soosyze CMS is a content management system without a database. It's easy to create and manage you

Soosyze 41 Jan 6, 2023
A small CMS for SaaS - A tiny content management system

Fervoare CMS A tiny content management system Project created in 2012 and ported to GitHub in 2021. Getting started Assuming you have installed a LAMP

Mark Jivko 3 Oct 1, 2022
Baicloud CMS is a lightweight content management system (CMS) based on PHP and MySQL and running on Linux, windows and other platforms

BaiCloud-cms About BaiCloud-cms is a powerful open source CMS that allows you to create professional websites and scalable web applications. Visit the

null 5 Aug 15, 2022
Simple Content Management System (CMS) Blog Using Codeigniter with Hierarchical Model View Controller (HMVC) Architectural

Simple Content Management System (CMS) Blog Using Codeigniter with Hierarchical Model View Controller (HMVC) Architectural This is my source code trai

Simon Montaño 1 Oct 28, 2021
Simple, modular content management system adapted for launch pages and one-page websites

Segmint Segmint is an easy-to-use flat-file landing page framework, allowing quick and efficient prototyping and deployment - perfect for freelancers

null 2 Jul 19, 2022
Monstra is a modern and lightweight Content Management System.

Monstra is a modern and lightweight Content Management System.

Monstra Content Management 398 Dec 11, 2022