How To Send Email With Django - Python Django Dentist Website #7

Поделиться
HTML-код
  • Опубликовано: 24 сен 2024

Комментарии • 207

  • @Codemycom
    @Codemycom  4 года назад +28

    UPDATE: You may have to set the email port without quotes....
    EMAIL_PORT = 587

    • @raspberry9417
      @raspberry9417 4 года назад

      how about port 465, do you have demos?

    • @SaeedAlFalasi
      @SaeedAlFalasi 4 года назад

      that explained ! thank you :D

    • @ilungantita8419
      @ilungantita8419 4 года назад

      Thanks a lot, really helped

    • @killcam8071
      @killcam8071 2 года назад

      Traceback (most recent call last):
      File "C:\arshia\Website\manage.py", line 22, in
      main()
      File "C:\arshia\Website\manage.py", line 18, in main
      execute_from_command_line(sys.argv)
      File "C:\arshia\Website\lib\site-packages\django\core\management\__init__.py", line 425, in execute_from_command_line
      utility.execute()
      File "C:\arshia\Website\lib\site-packages\django\core\management\__init__.py", line 419, in execute
      self.fetch_command(subcommand).run_from_argv(self.argv)
      File "C:\arshia\Website\lib\site-packages\django\core\management\base.py", line 373, in run_from_argv
      self.execute(*args, **cmd_options)
      File "C:\arshia\Website\lib\site-packages\django\core\management\base.py", line 417, in execute
      output = self.handle(*args, **options)
      File "C:\arshia\Website\lib\site-packages\django\core\management\commands\sendtestemail.py", line 29, in handle
      send_mail(
      File "C:\arshia\Website\lib\site-packages\django\core\mail\__init__.py", line 61, in send_mail
      return mail.send()
      File "C:\arshia\Website\lib\site-packages\django\core\mail\message.py", line 284, in send
      return self.get_connection(fail_silently).send_messages([self])
      File "C:\arshia\Website\lib\site-packages\django\core\mail\backends\smtp.py", line 102, in send_messages
      new_conn_created = self.open()
      File "C:\arshia\Website\lib\site-packages\django\core\mail\backends\smtp.py", line 69, in open
      self.connection.login(self.username, self.password)
      File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.2800.0_x64__qbz5n2kfra8p0\lib\smtplib.py", line 750, in login
      raise last_exception
      File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.2800.0_x64__qbz5n2kfra8p0\lib\smtplib.py", line 739, in login
      (code, resp) = self.auth(
      File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.2800.0_x64__qbz5n2kfra8p0\lib\smtplib.py", line 662, in auth
      raise SMTPAuthenticationError(code, resp)
      smtplib.SMTPAuthenticationError: (535, b'5.7.8 Username and Password not accepted. Learn more at
      5.7.8 support.google.com/mail/?p=BadCredentials e22-20020a170906505600b006da7d71f25csm1152188ejk.41 - gsmtp')

    • @killcam8071
      @killcam8071 2 года назад

      help me please

  • @adrianm.zapata6644
    @adrianm.zapata6644 5 месяцев назад +5

    Nice to have a young Walter White explaining these kind of things. Greetings from Chile.

  • @grayfaux_
    @grayfaux_ 2 года назад +4

    Less secure apps is no longer supported by Google. You need to enable 2 factor and set an app password in the google account. This way your email is not compromised by allowing less secure apps.

    • @Gabriel-ql7eb
      @Gabriel-ql7eb 28 дней назад

      and when hosted my site online, i don't have to use this smtp server thing in the video at 8:57, right?

  • @Hizar_127
    @Hizar_127 Месяц назад +1

    The code runs without throwing any errors. However, the email is not being received by the recipient. The email is also not appearing in the "Sent" folder of the sending Gmail account.
    i configured it everything but still email is not receiving

  • @apex4462
    @apex4462 2 года назад +1

    when i am using the request.POST method for name and other details like email, it doesn't get any value for the placeholder.

  • @bfarhan8
    @bfarhan8 3 года назад

    Ok, I start hating Django yesterday and was thinking about a career change, but now i am saying Django is awesome :D

  • @vijaykumarkarnan5223
    @vijaykumarkarnan5223 4 года назад +1

    your way of explanation is too good. please upload more videos.

  • @rubinashrestha1861
    @rubinashrestha1861 3 года назад +2

    Heyy, I did exactly the same thing as shown in the video but for some reason I am getting an error saying SMTPServerDisconnected. I have tried finding solution to the problem everywhere but I don't seem to find it.

  • @ricardofernandez2286
    @ricardofernandez2286 2 года назад +2

    Hi, thank you very much for these great tutorials!
    On this particular one I'm getting a couple of deprecation messages:
    C:\Python\lib\smtpd.py:105: DeprecationWarning: The asyncore module is deprecated and will be removed in Python 3.12. The recommended replacement is asyncio
    import asyncore
    C:\Python\lib\smtpd.py:106: DeprecationWarning: The asynchat module is deprecated and will be removed in Python 3.12. The recommended replacement is asyncio
    import asynchat
    How do you think we should transition from this solution to one that uses the new suggested library?
    Thank you very much!
    Warm regards
    Ricardo

  • @alexdin1565
    @alexdin1565 2 года назад +1

    please can you add an email tracker to check when receiver open URL

  • @FarhatJahan
    @FarhatJahan 4 года назад +2

    Hi, this video was really helpful. But I am facing one problem, i have app password and gmail account along with 2 factor authentication, but the received mail TO and FROM showing the same email id i.e. my own emial id. But when i tried with DebbungingServer everything was as expected.

    • @FarhatJahan
      @FarhatJahan 4 года назад +1

      I have understood why we should not be using user's email address in from field: stackoverflow.com/questions/62620601/to-and-from-return-the-same-email-id-in-django-send-mail

  • @mshoaib6106
    @mshoaib6106 4 года назад +1

    Excellent , Most Fav Instructor ever. LOVE YOU.:)

  • @raunakghawghawe4921
    @raunakghawghawe4921 3 года назад +1

    Got this error, please help :
    [WinError 10060] A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond

  • @J2LProductions
    @J2LProductions 4 года назад +3

    Everything works great! Awesome tutorial!! The only problem I have is that when someone sends me an email, the email sender is my own and doesn't show me the email that they typed in the email input. My code is exactly like yours.

    • @Codemycom
      @Codemycom  4 года назад

      Are you sure it's exactly the same?

    • @bektursunsamatuulu9772
      @bektursunsamatuulu9772 4 года назад

      Hi?
      Did you fix your problem? It seems like, the same problem that I am having now.

    • @R3N3C3K
      @R3N3C3K 4 года назад

      All of us have the same problem. I believe all of us are using the google smtp server and that will be the most probable problem... I believe Codemy's code works in the console. But when you switch to the google smtp, then the sender is the EMAIL_HOST_USER and not the email set in the form. Following code can redirect all information into message body. Unfortunately, I do not know how to print Full Name; Email Address; and Message fields at separate lines of the body text... :-( But I have the data.
      send_mail(
      'message from ' + message_name, # email_subject
      'Full Name: ' + message_name + '; Email Address: ' + message_email + '; Message: ' + message, # message
      message_email, # from email
      ['recepient1@example.com', 'recepient2@example.com'], # To Email
      )
      Or we can google how to force gmail to redirect sender from EMAIL_HOST_USER to the email address value set in the form. I has not been successful yet. But I believe there is some hidden magical switcher.

    • @R3N3C3K
      @R3N3C3K 4 года назад +1

      I have done some review and result posted at stackoverflow. It appears it is not posible to set properly the sender via gmail smtp. But I have quite solved the problem here:
      stackoverflow.com/questions/61518299/django-python-email-form-is-not-forwarding-senders-email-address-via-gmail-smtp

    • @jenilchudgar
      @jenilchudgar 2 года назад

      @@R3N3C3K You can use '
      '

  • @avishekthapa1774
    @avishekthapa1774 4 года назад +1

    in the send_mail function what is the point of writing message_email since the email we get is from the email we set in the settings files?? and also why does it work like this?

    • @zekafarzali6816
      @zekafarzali6816 3 года назад +1

      exactly, I was so confused why I receive an email from myself. Then it kicked in, it doesn't look right)

  • @karthikkumarmv9101
    @karthikkumarmv9101 3 года назад

    Sir I want send more input tag data at the place of massage in send mail function (I mean msg1,msg2...etc)wt should I want to do

  • @tudordraghici6154
    @tudordraghici6154 3 года назад +1

    Hei Jon, I have a question. I still did not manage to send an email. Some time passed and nothing happens. Can you please give me a hand over here ?
    PS. Great job, please keep up the good work you've done

  •  4 года назад

    thanks man, very helpful video. keep up the good work.

    • @Codemycom
      @Codemycom  4 года назад

      Glad you enjoyed it!

  • @fakeavangchhia3131
    @fakeavangchhia3131 Год назад

    Hello John! I really appreciate for all your tutorials but I am having a problem that the template I am using on my website does not have a contact.html instead it's have contact.php in forms how will i use this php forms
    can i please get help

    • @Codemycom
      @Codemycom  Год назад

      There might be some way to hack it, but I wouldn't know it. PHP doesn't work with Django.

  • @Shivam-sf5im
    @Shivam-sf5im 3 месяца назад

    hi sir what is the Windows equivalent command for this --->>
    python -m smtpd -n -c DebuggingServer localhost:1025
    Does this still work ??

  • @bastiantokusumajaya4337
    @bastiantokusumajaya4337 2 года назад

    Is it better to use commercial email like gmail etc or it is better to setup our own mail server like using postfix?

  • @lissankoirala
    @lissankoirala 4 года назад +1

    Thanks for this wonderful video sir, really helpful!

    • @Codemycom
      @Codemycom  4 года назад +2

      Glad it was helpful!

  • @thinhtran7268
    @thinhtran7268 2 года назад +1

    SMTP AUTH extension not supported by server. Help me, please

  • @rootuser5652
    @rootuser5652 3 года назад

    i watched this video exactly one year AFTER the release lol. PS. google security is better than.. nevermind haha NICE VIDEO!

  • @esspi9
    @esspi9 3 года назад

    Hey! Was this a part of any playlist?
    It says #7, but I couldn't find a django dentist playlist on your channel.

    • @Codemycom
      @Codemycom  3 года назад

      Link in the comment section: bit.ly/2tEBTzg

  • @joudalshuaibi2712
    @joudalshuaibi2712 3 года назад

    Hello,
    Thank you for your amazing videos.
    I have one question,
    I sent an HTML Email through Django but i need to take the users (who receives the email)'s response ( it's either Accept or reject through Radio button). how can i take the response in any way . I'm open to all solutions.
    Thank you in advance.

  • @engaligamalengaligamal
    @engaligamalengaligamal 3 года назад

    Thanks... Video Helps :)
    can you used map google in django

  • @ange-dev854
    @ange-dev854 2 года назад

    thanks sir for that
    but now i can't send email i got error smtpauthenticationerror and i can't turn on less secure app please help me

  • @abdullahhazari918
    @abdullahhazari918 3 года назад

    I love you men you solve my problem with google ! :D

  • @hetshah7743
    @hetshah7743 3 года назад

    [Errno 11003] getaddrinfo failed
    I am getting this error, even after importing socket in settings.py
    Any solutions ?

  • @alexx1466
    @alexx1466 Год назад

    please make a video of how to connect to databases . i have the error of database coneccion error

    • @Codemycom
      @Codemycom  Год назад

      I have tons of videos on that on my channel.

  • @jakezimmerman9822
    @jakezimmerman9822 3 года назад +2

    I have this working locally, but for some reason, I get an SMTPAuthentication error when trying to deploy on heroku. Anyone else have this issue?

    • @jakezimmerman9822
      @jakezimmerman9822 3 года назад +1

      I decided to use mailgun instead of django's send mail function and it worked. Pretty much a copy/paste replacement.
      documentation.mailgun.com/en/latest/quickstart-sending.html#send-via-api
      Also, I wasn't installing my dependencies to my virtual env with pipenv install, and was seeing a bunch of ModuleNotFound errors.

    • @mahdidaoud
      @mahdidaoud 3 года назад

      maybe the error because you didn't set the .env in geroku itself

  • @okami5365
    @okami5365 4 года назад

    So Im stuck on something it could bea really dumb little thing that I am stuck on but I can't seem to grasp how you kept the local:8000 and the local:1025 at the same time and when I make two two git bashes for each I get a error for the localhost:8000? what should I do?

    • @Codemycom
      @Codemycom  4 года назад

      The two things shouldn't have anything to do with each other. What;s the error?

    • @okami5365
      @okami5365 4 года назад

      @@Codemycom the error shows that send_mail( has a problem
      ^

    • @okami5365
      @okami5365 4 года назад

      @@Codemycom I tried everything and it still doesn't work 😥

  • @sanketkumar_coder
    @sanketkumar_coder Год назад

    Google doesn't use less secure apps anymore, what are the alternatives?

    • @rcitaku1704
      @rcitaku1704 7 месяцев назад +1

      Hello, you probably dont need this anymore but for anyone who does, you go to Security in your gmail account, then enable 2FA (2 factor authentication) and then you make an app password, copy it and paste it in the settings email password and thats about it! Hope this helped!

    • @sanketkumar_coder
      @sanketkumar_coder 7 месяцев назад

      @@rcitaku1704 I also figured it out . thanks :)

    • @Gabriel-ql7eb
      @Gabriel-ql7eb 28 дней назад

      @@rcitaku1704 hi, how about smtp local server thing from video? Do we use it still while site is hosted online?

  • @eugenekwaka
    @eugenekwaka 4 года назад

    When I run the code in the browser at 11:24 I get a 'UnicodeError at /Contact.html/ encoding with 'idna' codec failed(UnicodeError: label empty or too long) ' I wonder what the problem is

    • @caelim3524
      @caelim3524 3 года назад

      same I did some googling and it appears to be an error with windows. I couldn't find a fix

  • @deadandgone70
    @deadandgone70 3 года назад

    The two factor authentication one works but the less secure app way doesn't as of November 2020

  • @ai.201
    @ai.201 4 года назад

    Thanks Sir. You are doing great job.

  • @SaeedAlFalasi
    @SaeedAlFalasi 4 года назад +1

    If anyone has errors using the send_mail() function you have to pass the arguments in the exact order send_mail(subject, message, from_email, recipient_list) I ended up concatenating message_name with message_subject and message_email with message_phonenumber as i required the persons phone number.

    • @Codemycom
      @Codemycom  4 года назад

      interesting

    • @psicologiaobversa
      @psicologiaobversa 4 года назад

      I have this error with send_mail(
      And:
      Exception value: SMTP AUTH extension not supported by server
      I’m using:
      message_subject,
      message,
      message_email,
      [myemail@email.com],
      )
      I have changed the order several times and still got error on that.

    • @SaeedAlFalasi
      @SaeedAlFalasi 4 года назад

      @@psicologiaobversa the error says the server is not accepting the authentication or its unsupported

    • @psicologiaobversa
      @psicologiaobversa 4 года назад

      Any idea on that?

  • @gamingzonebk5943
    @gamingzonebk5943 4 года назад

    Really helped me great thanks for the video

  • @srivallisb2309
    @srivallisb2309 4 года назад

    Hi, I liked this video, but I wanted to know how to send reminder emails at a specific time. Can you help me out?

    • @pranavrawlani111
      @pranavrawlani111 3 года назад

      you have to use cron jobs with it

    • @pranavrawlani111
      @pranavrawlani111 3 года назад

      ruclips.net/video/5jaESVKqUs4/видео.html this link should help

  • @technologybysrk8419
    @technologybysrk8419 Год назад

    Thank you for what you do for us

  • @hibas7568
    @hibas7568 4 года назад

    hi :) I have 'phone number ' on my contact form..but im not able to send it through send_mail. Is there any other way to send mail where i can add other parameters i want?

    • @dmytrozimin7240
      @dmytrozimin7240 4 года назад +2

      Maybe you can try to put it to the message by concatenating it, thus you would get the mobile number inside the message. Just an idea:)

  • @nowyouknow2249
    @nowyouknow2249 4 года назад

    Thanks
    It was really helpful

    • @Codemycom
      @Codemycom  4 года назад

      Awesome, glad it was helpful!

  • @delllatitude299
    @delllatitude299 4 года назад

    awesome video.
    i have a quick question. how many emails we can add into SentToEmail List .

    • @Codemycom
      @Codemycom  4 года назад +1

      you can't use them to send spam, if that's what you're asking.
      docs.djangoproject.com/en/3.0/topics/email/#send-mass-mail

    • @delllatitude299
      @delllatitude299 4 года назад

      @@Codemycom kind of. basically i want to send mulitple emails to different peoples at a time. we can use loop or something iterations. but i want to know the best practice to do this so we can avoid to send mails in spam folder. I hope you got my point.

    • @Codemycom
      @Codemycom  4 года назад

      @@delllatitude299 Yeah, check that link I posted...that's the django docs for sending multiple emails...

    • @delllatitude299
      @delllatitude299 4 года назад

      @@Codemycom thanks. really appreciated your quick response. Please keep posting good content.

    • @Codemycom
      @Codemycom  4 года назад

      @@delllatitude299 Will do!

  • @amanjain6680
    @amanjain6680 3 года назад

    Why do i alway get connectionAbortedError?

  • @bektursunsamatuulu9772
    @bektursunsamatuulu9772 4 года назад

    Thank you for the videos. I appreciate it. I have one question to make sure.
    Now, I am using the second way of sending an email. My question when users fill out the form Get In Touch, I am receiving an email to my account but I have no idea who is sending it. How can I know who filled out the form? I want to know person's email for a reply to him/her later, as it says, - "We received your email and will respond shortly..." Somehow, I need to know an email of the user in order to reply back. Right?
    Looking forward to your reply.
    Thanks again.

    • @Codemycom
      @Codemycom  4 года назад

      Didn't I cover that in the video?

    • @bektursunsamatuulu9772
      @bektursunsamatuulu9772 4 года назад

      @@Codemycom Do you mean this one, 4:44 ?
      Here is my code:
      def contact_us(request):
      if request.method == 'POST':
      message_name = request.POST.get('message-name')
      message_email = request.POST.get('message-email')
      message = request.POST.get('message')
      # send an email
      send_mail(
      message_name, # subject
      message, # message
      message_email, # from email
      ['example@gmail.com'], # To Email
      )
      return render(request, 'dent/contact.html', {'message_name': message_name})
      return render(request, 'dent/contact.html', {})
      What's wrong?

    • @bektursunsamatuulu9772
      @bektursunsamatuulu9772 4 года назад

      Updated. No need to reply. Thanks.

    • @suhanisinha21
      @suhanisinha21 4 года назад +1

      @@bektursunsamatuulu9772 hey! I am still not receiving the email of the person filling out the form. How did you get it? Please help.

    • @bektursunsamatuulu9772
      @bektursunsamatuulu9772 4 года назад

      @@suhanisinha21 heeey sorry for late.. Is it works now?

  • @tamiltechguyz7264
    @tamiltechguyz7264 3 года назад

    Sir I am following all your videos but request to share ne the roles and permission access to templates in decorators

    • @Codemycom
      @Codemycom  3 года назад

      What are you talking about? There's nothing to share

    • @tamiltechguyz7264
      @tamiltechguyz7264 3 года назад

      @@Codemycom share me the decorator tutorials on django

  • @rangabharath4253
    @rangabharath4253 4 года назад +1

    Thank you so much

    • @Codemycom
      @Codemycom  4 года назад

      You're very welcome!

  • @ameerhbaig
    @ameerhbaig 4 года назад

    Thanks for this tutorial :)

  • @R3N3C3K
    @R3N3C3K 4 года назад

    In comments under the video, many people mentioned that gmail is not forwarding sender's email address. Here is designed method how I have bipassed the issue and have got all dynamic content into the message: stackoverflow.com/questions/61518299/django-python-email-form-is-not-forwarding-senders-email-address-via-gmail-smtp

  • @sabinkatwal8185
    @sabinkatwal8185 4 года назад +1

    Thank you sir.

  • @scottnorman2485
    @scottnorman2485 2 года назад

    Love your videos, but this error keeps ocurring...
    ConnectionRefusedError
    [WinError 10061] No connection could be made because the target machine actively refused it

  • @mohitkothari3300
    @mohitkothari3300 4 года назад

    my command prompt showed me details of the email but I haven't received it. So the module worked but only 50%

    • @Codemycom
      @Codemycom  4 года назад +1

      Yeah it's a hacky sort of thing...

  • @AntonioOrdaz1
    @AntonioOrdaz1 4 года назад

    Is it better to do it with CBV?

    • @Codemycom
      @Codemycom  4 года назад +1

      Not better, just different.

  • @AnnoyingErrors41
    @AnnoyingErrors41 4 года назад

    Production version at 14:37

    • @Codemycom
      @Codemycom  4 года назад +1

      ok

    • @AnnoyingErrors41
      @AnnoyingErrors41 4 года назад

      @@Codemycom LOL, just for people looking for a quick fix. No taunts!

  • @ДенисМаслов-у2е
    @ДенисМаслов-у2е 3 года назад

    Thank you very much!!

  • @Kruiger1993
    @Kruiger1993 3 года назад

    Great video in general just bummer that you didn’t show how it looks like in the html file

  • @ryan_0337
    @ryan_0337 4 года назад

    Thanks for the video.
    Do you know how we could send a text in a phone number in what app ?
    Morover,
    I smashed the like button since I saw the video

    • @Codemycom
      @Codemycom  4 года назад

      Thanks for smashing the like button! It's my favorite thing. Yes you can send a text message, but it's too complicated to talk about here...maybe I'll do a video on it later.

    • @ryan_0337
      @ryan_0337 4 года назад

      @@Codemycom ok and are you going to explain how to deploy the app ?

    • @Codemycom
      @Codemycom  4 года назад +1

      @@ryan_0337 yes

    • @SaeedAlFalasi
      @SaeedAlFalasi 4 года назад

      @@ryan_0337 Look at Amazon SNS service for SMS texts, whatsapp you would prob need to register a business account with them im sure they have documentations on it

    • @SaeedAlFalasi
      @SaeedAlFalasi 4 года назад

      @@Codemycom I seen an whatsapp python API using twilio but havent messed around with it yet. i couldnt find any other python whatsapp for business APIs

  • @ИгорьКузнецов-т8р
    @ИгорьКузнецов-т8р 4 года назад

    Hi! I know that with django it's possible to send several email's at once from site. Can you explaine ho to do it? or maybe even make special video?!

    • @Codemycom
      @Codemycom  4 года назад +1

      I'm not going to do a video on that because people will just use it to spam. But you can read the Django Docs yourself: docs.djangoproject.com/en/3.0/topics/email/#send-mass-mail

  • @diptabarman5756
    @diptabarman5756 4 года назад

    it is not working after deploying

  • @sameergaikwad1885
    @sameergaikwad1885 4 года назад

    Thanks... Video Helps :)

  • @troyforrester1991
    @troyforrester1991 4 года назад

    Respect for this one

  • @investandcyclecheap4890
    @investandcyclecheap4890 2 года назад

    Im getting a depreciated warning when running DebuggingServer . Is anyone else getting this? I havent been able to receive an email from my localhost yet...
    $ python -m smtpd -n -c DebuggingServer localhost:1025
    C:\Users\...\AppData\Local\Programs\Python\Python310\lib\smtpd.py:104: DeprecationWarning: The asyncore module is deprecated. The recommended replacement is asyncio
    import asyncore
    C:\Users\...\AppData\Local\Programs\Python\Python310\lib\smtpd.py:105: DeprecationWarning: The asynchat module is deprecated. The recommended replacement is asyncio
    import asynchat

    • @Codemycom
      @Codemycom  2 года назад

      No clue...but you can always just try to do what it says and see what happens.

    • @alexandra.thegreat
      @alexandra.thegreat 2 года назад

      I'm having the same issue. Have you managed to solve it? thanks ;-)

  • @nafiyad1950
    @nafiyad1950 4 года назад

    What is your django version

    • @Codemycom
      @Codemycom  4 года назад

      Not the latest version

  • @LAEC91
    @LAEC91 3 года назад

    Sad but true. Not many people have 2FA turned on.

  • @killcam8071
    @killcam8071 2 года назад

    nice job man❤❤❤

  • @rahulrajeev9879
    @rahulrajeev9879 Год назад

    🔥poli sanam 💫

  • @anandsarank
    @anandsarank 3 года назад

    Hi, Can anyone help me with this. I am getting - Exception Type: OSError at /contact.html
    Exception Value: Int or String expected

    • @bfarhan8
      @bfarhan8 3 года назад

      Try Stackoverflow

  • @AnilThapa-jx1fc
    @AnilThapa-jx1fc 4 года назад

    Hello Sir All This Worked Perfectly But only problem i didnt recieved mail

  • @rohit45kashyap
    @rohit45kashyap 4 года назад +1

    When i m sending mail it always send
    From : setting.py file email address (EMAIL_HOST_USER)
    To: views.py recipient list
    Then what is mean of taking user email id
    The mail should go from User Email Id to recipent list. So what should i do?
    Please help

  • @I_Follow_Jesus
    @I_Follow_Jesus 4 года назад

    Thanks!

  • @janicesombillo8147
    @janicesombillo8147 4 года назад

    why is that when i send email the sender is always the receiver?

    • @Codemycom
      @Codemycom  4 года назад

      because that's how you set it up in your code.

    • @janicesombillo8147
      @janicesombillo8147 4 года назад

      But my code is exactly like yours and its not showing the senders email

    • @janicesombillo8147
      @janicesombillo8147 4 года назад

      @@Codemycom please help

    • @Codemycom
      @Codemycom  4 года назад

      @@janicesombillo8147 Just look at the code, you must have the same email twice...right? That's not correct if you want to send email to two different email addresses...

    • @janicesombillo8147
      @janicesombillo8147 4 года назад

      @@Codemycom the problem is it doesnt show the senders email

  • @alialavizadeh2775
    @alialavizadeh2775 3 года назад

    that was great, tnx

  • @alimomeni3535
    @alimomeni3535 3 года назад

    gooood , nice

  • @imtiyazahamedchowdhury2822
    @imtiyazahamedchowdhury2822 3 года назад

    Please help ! i set same things in my local host its working but after upload its not working from hosting . no massage send from account . so what i have to change in setting when i upload project in real hosting ?

  • @fustigate8933
    @fustigate8933 3 года назад

    the thumbnail...your right hand...

  • @malborocomun
    @malborocomun 2 года назад

    i can't believe is that fucking easy

  • @yusufyahya955
    @yusufyahya955 3 года назад

    raise SMTPServerDisconnected('please run connect() first')
    if you had this error you my be want install this :
    pip install django-smtp-ssl
    this one to istall library smtp and ssl protokol

    • @manpatel783
      @manpatel783 3 года назад +1

      That's not a smpt actually it is smpts

    • @ravindrakumara.
      @ravindrakumara. 3 года назад

      still had same error, afeter added pip install django-smtp-ssl

  • @dropdeaddavi440
    @dropdeaddavi440 2 года назад

    As of May 2022 Gmail no longer supports less secure app access, leaving this comment here in case there's an updated way of doing this

  • @ram_qr
    @ram_qr 4 месяца назад

    👍👍👍👍👍

  • @bourki-dev8014
    @bourki-dev8014 3 года назад

    this dosnt work pff

    • @Codemycom
      @Codemycom  3 года назад

      It doesn't work if you mess it up

  • @saxophone69
    @saxophone69 3 года назад

    disappointing not to have been able to see this work

    • @Codemycom
      @Codemycom  3 года назад

      you did see this work, and then you commented on it...?

  • @Codemycom
    @Codemycom  4 года назад

    ▶️ Watch Entire Money Making Playlist ✅ Subscribe To My RUclips Channel:
    bit.ly/2tEBTzg bit.ly/2IGzvOR
    ▶️ See More At: ✅ Join My Facebook Group:
    Codemy.com bit.ly/2GFmOBz
    ▶️ Learn to Code at Codemy.com
    Take $30 off with coupon code: youtube1

  • @muhammadhassanbutt9305
    @muhammadhassanbutt9305 3 года назад

    plz share what is in your model.py

  • @dailypythontests
    @dailypythontests 2 года назад

    great tutorial John, but I didn't see you utilize this: EMAIL_BACKEND = 'django.core.mail.backends.smtp.EmailBackend' I think it's really important

    • @Codemycom
      @Codemycom  2 года назад

      why would you think that?