так кнопка заблокируется, но при обновлении страницы то она появится снова (или другой человек зайдет, у него она не будет заблочена)
It means that PHPMailer is unable to contact the SMTP server you have specified in the Host property, but doesn't say exactly why. It can also be caused by not having the openssl extension loaded
Enabling debug output
If you're using SMTP (i.e. you're calling isSMTP()), you can get a detailed transcript of the SMTP conversation using the SMTPDebug property. The settings are as follows:
1: show client -> server messages only. Don't use this - it's very unlikely to tell you anything useful.
2: show client -> server and server -> client messages - this is usually the setting you want
3: As 2, but also show details about the initial connection; only use this if you're having trouble connecting (e.g. connection timing out)
4: As 3, but also shows detailed low-level traffic. Only really useful for analyzing protocol-level bugs, very verbose, probably not what you need.
Set this option by including a line like this in your script:$mail->SMTPDebug = 2;
3. Проверьте в Гугл аккаунте разрешен ли доступ ненадёжных приложений...
# Выводит содержимое "/some/path"
print(list(y.listdir("/some/path")))
, а потом тупо скачать что надо.. # Скачивает "/some-file-to-download.txt" в "downloaded.txt"
y.download("/some-file-to-download.txt", "downloaded.txt")