Can't send mail using mail plugin from browser

Hi,
Can you please tell me why this situation happens and how can i fix it: i can send mail using the mail plugin, by running the application from Servoy (ctrl + L) but i can’t send an email when i run the application in a browser. The mail is just not sent to it’s destination… Do you know why?

DB

It should work just fine, did you try to turn on the debugger to see what’s happening?

Thank you for answering me Nicola!
When i run the solution from Servoy application, it all works fine, as i said… I can use the debugger to see what is happening in the browser? How can i do this? I am mentioning that i am using a multideveloper,I don’t know if this makes a difference within this problem… What do you think?
DB

Hi Diana,

could this be a firewall issue on your server? The mail plugin will send it’s email from the server…

So you are on servoy 3.5. You can’t use the debugger for the webclient in 3.5.
Probably it’s a firewall issue on the server as mboegem pointed out.

I have set an exception on the port that Servoy application is on and i tested the link from an external computer, it all worked but the mail functionality… Are there other firewall settings that should be done that i am not aware of?

DB

Hi Diana,

the exception depends on which port is used for the connection to your smtp server. Most common are port 25 and 587 (i.e. for Gmail).

Hi Marc,
I have turned off firewall and still no change… Could it be a server configuration setup?

Diana

Just some ideas for troubleshooting…

-Check the FROM address in your email. Most email servers required a known domain on the outgoing address or they won’t relay.
-Try putting in some manual debugging lines into your code to display the variables you’re passing. Maybe something isn’t what you think.
-Is your email going out, but getting caught by a spam blocker on the recipient end?
-Check the server log by logging into http://localhost:8080/servoy-admin.
-Try using a different email server for the outgoing mail. I use my Yahoo account pop settings and it works well for testing. (not sure if you need a premium account on yahoo to use pop).
-Drop back to an extremely basic email (no attachments, one recipient, send to an email address on your mailserver, etc) and see if you can get anything to work.

Can you send your code where you form the email and try to send it? Maybe we can see something. We use email for both web and smart clients quite often and it does work just fine if the settings are correct.

–Jason

Thank you for all your good advises Jason!
The exception was:
“Could not connect to SMTP host: localhost, port: 25”
As i said, the SMTP server was set in Preferences → Mail, i don’t understand why this happened…
So in my send mail method i have overwritten the SMTP preferences and it worked from the browser also,finally! :)
Thank you all for looking into my problem, this forum is absolutely great!
Diana