Introduction
This article aims to help you with the “Mail() function returned false” error, which can appear on the contact page of your site created with SitePad.
Prerequisite
Enter the following address in your web browser : https://mg.n0c.com/en.
Connect to SitePad as explained in Website Creation with the SitePad Site Builder.
Fixing the “Mail() function returned false” error
Sometimes this error is displayed at the bottom of the screen:

If this happens, please follow the instructions below:
- Once logged in to SiteBuilder, go to Parameters -> Contact Form:

- Enter an email account with the same domain as your hosting in the To and From fields (you will be able to redirect your messages to another address in your N0C panel).
- Click on the green Publish button to publish the changes.
- Once the changes are published, go to the file manager via the N0C panel and edit the file named “contact.php” :

5. Enter the following two lines as comments in the code :
//$headers .= "Reply-To: " . (!empty($this->replyto) ? $this->replyto : $this->from) . "" . PHP_EOL;
//$headers .= "Return-Path: " . $this->from . "" . PHP_EOL;

- Click on the Save and Close buttons.