You can use context or string concatenation to pass a specific type of user
a specific message
you can do it by and if statement where
if request.user == admin :
then the below code for it
subject = 'Techela 6.0 Registration'
from_email = settings.DEFAULT_FROM_EMAIL
thanks very much but base on your code you are sending all the message to
user. i want to send a specific message to admin emails like
form input data than and also send to user such as welcome message
On Saturday, July 3, 2021 at 2:10:21 PM UTC+1 get...@gmail.com wrote:
> from
from django.conf import settings
from django.core.mail import send_mail
def valorant_view(request):
if (valorant_registration.objects.count() <= 160):
if request.method == 'POST':
first_name = request.POST['first_name']
last_name = request.POST['last_name']
i am currently building a contact us form.
when my users filed the form and submit it will send them welcome message
and send also forward the user data to my email.
i was able to used mailMultiAlternatives to achieve sending the html
template to my users with the code below.
4 matches
Mail list logo