Hi An,
I understand now. It would be possible to implement this for "most" features, by using a site specific prefix for the settings in <appSettings related to smtp, kind of like I did for commerce settings as indicated in this article. All the custom mojoportal features use these smtp settings from the appSettings section of Web.config, but built in ASP.NET features use the settings from the system.net/mailsettings section:
<system.net>
<mailSettings>
<smtp from="noreply@yourdomain.com">
<network
host="localhost"
port="25"
password=""
userName=""
/>
</smtp>
</mailSettings>
</system.net>
The only feature I know of where this will be used in mojoportal is the password recovery feature because that uses the built in ASP.NET password recovery control, so maybe its not a problem there.
If you want to implement an SmtpConfig.cs similar to what I did for commerce in Web/Components/CommerceConfig.cs, that would make it possible to hide this complexity of config settings from other places in the code. I could implement this myself in an hour or less I think, but if you want to tackle it that would be great. If not, let me know and I'll see what I can do.
Best,
Joe