Friday, January 7, 2022

linebreaksbr doesn't work

Hi, why linebreaksbr might not work {{somevalue | linebreaksbr}}

For example, somevalue = 'Joel\nis a slug', and linebreaksbr doesn't change \n → <br>

----------------------

{% load static %}

<!DOCTYPE html>

<head>


</head>

<body>

<code>

<p>

{{somevalue | linebreaksbr}}

</p>

</code>

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/0d366e7f-c316-4a13-ac97-947d23326105n%40googlegroups.com.

No comments:

Post a Comment