ya i dont want to hide senders email address or identity...but user can enter any email id in from and to fields....so how can i get smtp server for that account's ISP??
If this is the case then you would have the user enter their smtp server address. As with most ISP's today in order to send email through their smtp server you must have a email account and log on with a user id and password this keeps people from using false return email address and using their smtp servers to relay SPAM.