Closed ogurec-ogurec closed 4 years ago
Django templates are not used to render comments when using the ReactJS plugin. But you don't have to change the code of the plugin, there's a solution for what you are trying to do. I recently updated the docs with a use case covering this situation: Change user image or avatar. Your particular case is documented in the section "When using the web API".
Thanks
I am trying to put my avatar next to a comment. For example, I want to remove the "gravatar". Editing template _templates/django-comments-xtd/commenttree.html I remove the line:
<div class = "mr-3"> {{item.comment.user_email | xtd_comment_gravatar}} </div>
And I insert:
<img src = "{{user.profile.image.url}}" width = "100" height = "100">
But nothing happens (the avatar is still a gravatar). Also I try to edit html through templates other changes in code - nothing comes out. Changes are only received if I make changes to js (plugin-2.7.1).
How to edit html templates correctly?