


You may have your website setup, so a user can simply sign up, create a piece of content, and then have it published immediately. An example of this is a Company Profile. To keep strict control of page stylings, you may want to force an Input Format upon the Company Profile. For example, a format that doesn't allow tags or even depricated HTML attributes, such as, "bgcolor" and "color".
For such control over user roles and input formats, you should use the Better Formats module.
In this example, we will create an Input Format called "Profile HTML" which is to be used only for the "Company Profile " nodes.
To do this, download and install the Better Formats module.
Then go to:
Now under the "Configure" tab. You need to check "Strip disallowed tags". And also enter a list of allowed tags, anything not listed here, will be automatically stripped by the Input Format.
Click "Save"
Now we actually want to delve into the "Better Format" module.
Before we do anything, we must ensure that the roles have the permission to access the Input Format, go to Admin > Input Formats and then configure the format you want to edit. Ensure you check the roles you wish to access the format.
Once you activate the Better Formats module and then go to Admin > Input Formats
In the "Defaults" tab you can set the "Node Defaults" for Input Formats. So you can have Admin set to "Full HTML" and then assign the Company user role to "Profile HTML" and so on.
If you want to assign an input format based on a Content Type as opposed to a role, you can go to the Settings tab and check "Control formats per node type" at the bottom.
Once this is enabled, go to Admin > Content Types and edit the content type you wish to change. Under Your Content Type > Input Formats you can then select which formats are allowed for the content type.
If your "Member" role is allowed to create a "Member Page" - then edit the "Member Page" content type and then check "Filtered HTML" or "Strip Everything" content type you can create - so all content styles are stripped from the text that they paste into the editor.
Another handy aspect of this module to remove the "more about input formats" message that appears when you create a page.
Go to Admin > Permissions and you will see the module sets a lot of permissions for these settings. Uncheck the rules "show format tips" and "show more format tips link" and this will hide the messages you receive when you only have 1 format available.
Post new comment