![]() Elements such as page links and images need to preserve metadata such as the page or image ID, which is not present in the final HTML representation.Enforcing a subset of HTML helps to keep presentational markup out of the database, making the site more maintainable, and making it easier to repurpose site content (including, potentially, producing non-HTML output such as LaTeX).Rich text fields can specify a features argument to further restrict the elements permitted in the field - see Limiting features in a rich text field.The editor interface needs to filter out certain kinds of unwanted markup this includes malicious scripting, font styles pasted from an external word processor, and elements which would break the validity or consistency of the site design (for example, pages will generally reserve the element for the page title, and so it would be inappropriate to allow users to insert their own additional elements through rich text).In reality, it’s necessary to give editors a representation of rich text content that is several steps removed from the final HTML output, for several reasons: Managing documents, images, snippets and collectionsĪt first glance, Wagtail’s rich text capabilities appear to give editors direct control over a block of HTML content.Copying and creating aliases to existing pages.Previewing and submitting pages for moderation.Inserting links to documents into body text.Customising CreateView, EditView and DeleteView.Customising IndexView - the listing view.Customising the user account settings form.How to use a redirect with Form builder to prevent double submission. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |