Upload doesn't work
loviuz opened this issue · 3 comments
Hi,
I am configuring the bot to try to build my bot, but I cannot make the upload works... I have configured database, upload paths, etc, but after the upload the bot does not reply. When i send /upload command it replies with "Please upload the file now", after the upload I cannot get any response.
I'm using PHP7.4.
In the apache logs I can see that apache responds with a 200 response code and I have no PHP errors :-(
Hi @loviuz, this is probably due to not having the correct GenericmessageCommand.php
file in your custom commands folder.
As the /upload
command makes use of the conversations, you can copy this GenericmessageCommand.php
next to your UploadCommand.php
.
Try again then and let me know if it works. To test, make sure to only have those 2 files in the folder 👌
I have tried the standard upload class, I think this should already work as it is, right? I have configured Download and Upload path and database connection, but it seems that after the script answer with "upload your photo" phrase the script will not receive the second input: the image. I don't know telegram API very well, but it seems that all of this should happens inside a conversation or something similar, something that should track my first request and the second input (the image). I'm italian, I hope I've been explained my problem... 🙄
Have you tried my suggestion?
You must have the UploadCommand.php
AND GenericmessageCommand.php
files in your custom commands path.