Changed contact form formatting
This commit is contained in:
parent
167939beae
commit
7c91907e6e
@ -26,7 +26,7 @@ def contact(request):
|
|||||||
result = False
|
result = False
|
||||||
if name is not None and email is not None and subject is not None and body is not None:
|
if name is not None and email is not None and subject is not None and body is not None:
|
||||||
result = mail.send_mail('OACPL CONTACT: %(subject)s' % locals(), body, settings.EMAIL_HOST_USER, [settings.EMAIL_CONTACT],
|
result = mail.send_mail('OACPL CONTACT: %(subject)s' % locals(), body, settings.EMAIL_HOST_USER, [settings.EMAIL_CONTACT],
|
||||||
html_message=url_fix_render_to_string('email.html', {'content': '<strong>Someone has messaged you via the website contact form!<br><br>Subject:</strong> %(subject)s<br><strong>From:</strong> %(name)s (%(email)s)<br><br>%(body)s' % locals(), 'signature': ' '}))
|
html_message=url_fix_render_to_string('email.html', {'content': '<strong>Someone has messaged you via the website contact form!<br><br>Subject:</strong> %(subject)s<br><strong>From:</strong> %(name)s <%(email)s><br><br>%(body)s' % locals(), 'signature': ' '}))
|
||||||
|
|
||||||
return JsonResponse({'success': True if result else False})
|
return JsonResponse({'success': True if result else False})
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user