Pretty standard Django stuff: https://docs.djangoproject.com/en/dev/topics/templates/#automatic-html-escaping
Suggest skimming all the Django and Mezzanine documentation at least once, you'll be much better off for it. On Wed, May 7, 2014 at 11:49 PM, Rafael Reuber <[email protected]>wrote: > Actually I've used on my model But when my RitchTextField attribute is > used on a template it render the raw html value. > > For example: If the user write a texte like "This is the *project* one" > on django admin. > On my custom template it shows "This is the <strong>project</strong> one" > > > > This is my template: > > {% extends "base.html" %} > {% load i18n %} > > {% block meta_title %}{% trans "Home" %}{% endblock %} > {% block title %}{% trans "Home" %}{% endblock %} > > {% load pages_tags %} > > {% block main %} > > <div class="page-header"> > <h3>{{project.title}}</h3> > </div> > > {{project.description}} > > {% endblock %} > > Em quarta-feira, 7 de maio de 2014 03h46min37s UTC-3, Stephen McDonald > escreveu: >> >> Should be possible - blog posts use it, and they're not related to pages. >> >> What have you tried? >> >> >> On Wed, May 7, 2014 at 1:04 PM, Rafael Reuber <[email protected]>wrote: >> >>> It's possible tu use a RitchTextField on a django.db.models.Model or >>> just on mezzanine Page object? >>> >>> Em quinta-feira, 2 de janeiro de 2014 21h25min07s UTC-3, Stephen >>> McDonald escreveu: >>>> >>>> If you'd like a single content field on your model, subclass >>>> mezzanine.core.models.RichText, eg: >>>> >>>> https://github.com/stephenmcd/mezzanine/blob/master/mezzanin >>>> e/pages/models.py#L268 >>>> >>>> If you'd like more control, and want to specify one or more RichText >>>> fields yourself, just use mezzanine.core.fields.RichTextField, eg: >>>> >>>> https://github.com/stephenmcd/mezzanine/blob/master/mezzanin >>>> e/core/models.py#L293 >>>> >>>> >>>> On Fri, Jan 3, 2014 at 11:01 AM, Karthik Kannan <[email protected]>wrote: >>>> >>>>> Hello, >>>>> >>>>> I'm trying to use a rich text field for one of the text areas in my >>>>> mezzanine project. Can anyone point to some examples/documentation related >>>>> to rich text fields? Trying to find examples of its usage but in vain. >>>>> >>>>> Thank you for your help. >>>>> >>>>> Karthik. >>>>> >>>>> -- >>>>> You received this message because you are subscribed to the Google >>>>> Groups "Mezzanine Users" group. >>>>> To unsubscribe from this group and stop receiving emails from it, send >>>>> an email to [email protected]. >>>>> >>>>> For more options, visit https://groups.google.com/groups/opt_out. >>>>> >>>> >>>> >>>> >>>> -- >>>> Stephen McDonald >>>> http://jupo.org >>>> >>> >> >> >> -- >> Stephen McDonald >> http://jupo.org >> > -- > You received this message because you are subscribed to the Google Groups > "Mezzanine Users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/d/optout. > -- Stephen McDonald http://jupo.org -- You received this message because you are subscribed to the Google Groups "Mezzanine Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
