We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 18397
    • 3,250 Posts
    Chunks are bits of text or code that can be reused throughout a site. These are primarily html but can also be javascript, css, or text. They are called within a document, snippet, TV, or template like so:


    Snippets are bits of PHP code that are used to add additional functionality to a site. These are most often used for menus but are also used for galleries, guestbooks, comments, forms, etc. They are called within a document, TV, chunk, or template like so:


    Or, if parameters are needed:


    TVs are template variables and are values assigned to a particular document. They can be used to specify anything specific to the current page included a header image, sidebar items, category, author name, etc. These can be called within a document, chunk, or template like so:


    Plugins are PHP scripts that can interact with MODx events. These eliminate the need to edit the core (most of the time). Current examples included the Quickedit plugin and all Rich Text Editors (FCK Editor [by default], Xinha, and TinyMCE). These are executed when specific MODx events are called.

    Modules are large bits of code that can interact with plugins and all other MODx items. These are mainly used for backends for things like galleries (coming soon) and the new Quickedit function. These are run from within the Manage Modules page.
      • 1764
      • 680 Posts
        • 1876
        • 835 Posts

        I discover ModX terms and I find :

        Chunks : {{chunkname}}
        Snippets : [[snippetname]]
        plugin : [[plugin]]
        TV’s : [*tvname*]
        style tag : [*#styletag*]
        ??????? : [(site_name)]
        ??????? : [~[(site_start)]~]

        A complete summary would be welcome to print for memory


        • [(site_name)] and [(site_start)] are site-wide values, set in the System Configuration section of the Manager. Most of them aren’t really useful, but I often find use for those two, as well as [(emailsender)] for a link to send email to the webmaster in my page footers.

          The [~...~] tags tell the MODx parser to make a hyperlink out of the document ID that is enclosed in the tags. In the case of [~[(site_start)]~] it would be the ID of whatever document was set in the Site Configuration to be the first document shown when entering the site (1 by default).
            Studying MODX in the desert - http://sottwell.com
            Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
            Join the Slack Community - http://modx.org