added mail() code, doesn't work yet tho.
added mail() code, doesn't work yet tho.