- goodguy20k
- Posts: 71
- Joined: 10 Jan 2006, 23:58
- Location: Texas, USA
- Contact:
Can I specify more email settings? Like SMTP port? Can I use a SSL? My guess is no, but that I can do something like that through a Java extension. Just have to ask.
In order to send from Java you have to do the following:
All params in the sendMail() method are Strings
The method returns true if the email was sent successfully
hope it helps
Code: Select all
import it.gotoandplay.smartfoxserver.lib.MailManager
MailManager mailer = MailManager.getInstance()
mailer.sendMail(from, to, subject, message)
All params in the sendMail() method are Strings
The method returns true if the email was sent successfully
hope it helps
How it is possible to send messages with special characters (chinese for example) using this sendMail function?
Yes of course.
when I'm using mailer.sendMail(from, to, subject, message) it seems chinese characters are destroyed.
Suggestion: save your message as an external UTF-8 text or html file and load it at runtime in the server extension. This way you don't have to change your extension in order to modify the message and the UTF-8 will preserve all the foreign characters.
hope it helps
Return to “Server Side Extension Development”
Who is online
Users browsing this forum: No registered users and 18 guests