Why did ModX choose to store the documents in a database, instead of simply making modx a front-end to standard html, css, js, etc files?
That way, developers could simply edit the back-end files if they wanted to. Seems there would be other advantages as well.
True, we can accomplish that with the "static" document type on a one-by-one basis. But overall the system is not designed around the file architecture.
jealousy<>love
Simple answer MODX uses a database to store most of its information but you can use files if you so wish.
One way is to use an include snippet to reference your files.
some developers use this only for development and deploy to a database.
A database is safer than files in general.
Checkout the various tutorials.
If you really want a file system CMS I would try something else as the developers have chosen to work with a database.
DEVELOPMENT ENV:- Ubuntu 12.04 | MODx Revolution 2.2.8 | LAMP 2i Apache 2.2.22 | Php 5.3.10 | Mysql 5.5.31 MySQL client version: 5.5.31
A database is also pretty handy when you want to search.
I don’t think it would be that difficult to implement, but since an "include" snippet is an easy workaround for chunks and you can "include" code in snippets, I don’t think it’s a high priority.
One day, when I’m only working one job, I’m going to get the MODx FUSE Filesystem thing back up and running. Which will magically fix this (but only if you’re developing on Linux or Mac).
Quote from: lossendae at May 02, 2011, 06:04 PM
Quote from: BobRay at May 02, 2011, 05:57 PM
I don’t think it would be that difficult to implement, but since an "include" snippet is an easy workaround for chunks and you can "include" code in snippets, I don’t think it’s a high priority.
What about caching ?
What about converting users to MODx ?
I’m not sure what you mean about caching. You can already control whether a chunk or snippet is cached -- with or without it’s code in a file.
As for converting users, I think making the product bug free, updating the docs, making the install more reliable, converting Evo add-ons, and allowing you to update MODX from the Manager are more important for that. I didn’t mean to imply that doing files was a bad idea, just that there are other things that have a higher priority right now.
@deflock
I took a look at modx fuse and found @shamblet has done some work on this and released an extra for Evo or Revo have not tried same but here is a link
http://modx.com/extras/package/modxfsphp
I have been using the ’include snippet’ with great success for dev work. To my knowledge your files could then be under a local or even remote Git or other version control system. I have personally not tried this yet but may be testing soon. At present I just comment out my changes till happy.
DEVELOPMENT ENV:- Ubuntu 12.04 | MODx Revolution 2.2.8 | LAMP 2i Apache 2.2.22 | Php 5.3.10 | Mysql 5.5.31 MySQL client version: 5.5.31