Using Files As Templates

light fare

Templates as Files

You can edit elements, including templates, as files if you prefer.

susprod asks...

Can I edit the template files directly to a page and just FTP the pages and have MODX pull them in?

The Solution

bobray says...

If it's MODX Revolution, you can set the Template as static. Then the Template's content exists as a file and you can do what you want with it.

What's the Story

All elements can be flagged as static with the "Is Static" checkbox. At that point, a new field appears for the path to the file. When you edit the element in the Manager it will modify the file. If you edit the file externally, the next time the element is loaded it will display the changed content. The file will be used as the source for the element instead of the content field of the database.

Static Elements