email - PHP mail function is not working on Hostgator -


this question has answer here:

i have use mail function in project. when host project on hostgator, doesn't work. when host on other server, works fine. can't understand problem. if know answer please explain or suggest me link can understand beginning. thank you. here code.

$to_address = "test@somedomain.com"; $subject = "this goes in subject line of email!"; $message = "this body of email.\n\n"; $message .= "more body: variable.\n"; $headers = "from: test@somedomain.com\r\n"; mail("$to_address", "$subject", "$message", "$headers"); 

supposing on hostgator.in & specially mentioned hostgator, not allow mail sending if domains other 1 on have hosted site. either sender or receiver's mail should same of hosting e.g. if ypu have site a.com either sender's mail id or receiver's mail id should have @a.com


Comments

Popular posts from this blog

java - WARN : org.springframework.web.servlet.PageNotFound - No mapping found for HTTP request with URI [/board/] in DispatcherServlet with name 'appServlet' -

android - How to create dynamically Fragment pager adapter -

1111. appearing after print sequence - php -