
That is a very bold statement, so bear with us for a moment while we explain. If you end up making changes to the way ContentBlocks looks, we would love to hear about that and consider including them in the next release.ĬontentBlocks radically changes the way you build websites in MODX, and perhaps even how you build websites in general. There are also lots of other classes that can be used to target styling. contentblocks-wrapper div, and each of the input types has its own. The ContentBlocks canvas is wrapped in a.
#MODMORE GITIFY FULL#
(If you also use Redactor, you could also use the redactor.css setting - that will also inject the stylesheet into the manager page and would save you using the above plugin.)Īs this will inject the CSS into the full manager page, you do need to be careful about scoping your CSS properly. In the plugin content, all you have to do is call $modx->regClientCss with the url to your CSS file, like this: getOption('base_url'). Simple create a new Plugin and set it to fire on the OnDocFormRender system event. Getting fancy with realistic previews of what content might look like on the front-end, or want to make some changes to the design of the canvas or certain input types?ĬontentBlocks doesn't expose a convenience method for loading additional CSS files currently, but it's incredibly easy to do thanks to the power of plugins in MODX. If none of these built-in options are specific enough for your usage, please get in touch with We may be able of providing you with a plugin to follow your business rules. To enable or disable ContentBlocks based on the template, see the next two FAQ entries that provide you with a plugin you can add to your MODX site to control template-based behaviour. Simply set it to Yes or No and then save the resource. Near the bottom of the tab you will notice a Use ContentBlocks? setting.

To enable or disable ContentBlocks on a specific resource, simple edit that resource and navigate to the Settings tab.

Give it a key of contentblocks.disabled, set the Field Type to Yes/No and set a value of 0 (to enable ContentBlocks in that context) or 1 (to disable ContentBlocks in that context). To enable or disable ContentBlocks in an entire context, create a new context setting for that context by right clicking the context in the tree, choosing Edit Context and clicking the Create New button on the Context Settings tab. When set to Yes, so disabled by default, it is possible to selectively enable it on more specific entities, such as contexts. Set to Yes to disable ContentBlocks, and set to No to keep ContentBlocks enabled by default. Under the Core area, you should see "Disabled" (with key contentblocks.disabled). In the first dropdown above the table, choose contentblocks to show all settings that belong to ContentBlocks. To enable or disable ContentBlocks system-wide, go to System (the cog icon in 2.3) and System Settings. By default, it is enabled for all resources across your MODX site.

Out of the box, ContentBlocks comes with a few options to decide when it is used and when it isn't.
