In my modelform I have a foreign key, I cannot figure out how to change the appearance of this field in template. I can change the text by changing
__unicode__
of the model, but how would I make it bold, for example?
in models.py I tried the following but form renders with and all other tags as if they were just text:
def __unicode__(self):
u'<b>Name</b>: {}\n<b>Loyal</b>: {}'.format(self.name, self.loyal)
my template.html:
<form method="post">
{% csrf_token %}
{{ form.client|safe}}
<br>
<input type="submit" value="Save changes" class="btn btn-s btn-success">
</form>
doesn't work.
Here is the picture: