question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Custom email templates

See original GitHub issue

Hi,

I was wondering how I can use custom mail templates for user activation, password reset and confirmation.

django-templated-mail uses get_template() to get the template file. I tried adding a global template file templates/email/password_reset.html in my root project folder and setting the 'DIRS': ['templates'] option, but djoser still get the template from the library, not my custom one. When using the django shell (python manage.py shell) and typing get_template('email/password_reset.html'), my custom template is returned.

Is there a way to easily override the mail templates?

Thank you!

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:8 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
tom-and-jarycommented, Sep 23, 2020

i fixed , becase i forgot change custom templates content

can worked code:

my config:

TEMPLATES = [
    {
        'BACKEND': 'django.template.backends.django.DjangoTemplates',
        # 'DIRS': [],
        'DIRS': [os.path.join(BASE_DIR, 'templates')], 
      ...  ... 

file local: projectName/templates/email/password_reset.html

0reactions
tomwojcikcommented, Sep 22, 2020
Read more comments on GitHub >

github_iconTop Results From Across the Web

Free Responsive Email Templates - Campaign Monitor
Free responsive email templates. Browse our selection of free mobile-friendly email templates, designed and optimized to be responsive and customizable.
Read more >
The 10 Best Sites for Free Email Templates - Sendinblue
Download over 3000+ free HTML email templates for professional email ... MailBakery also has a custom email template design offering if you ...
Read more >
Stripo — FREE Email Template Builder: Drag and Drop Html ...
Stripo — free email template builder. Create professional and responsive emails fast with no HTML skills. Use it to automate email production.
Read more >
1260+ Free HTML Professional Email Templates - Beefree.io
Browse over 1260 HTML email templates and download for free professional newsletter templates for every industry. Choose your template or hire a designer....
Read more >
Customize Email Templates - Auth0
You can customize the From Address, the Subject, and the Message body for each email template. You can use Liquid Syntax to dynamically...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found