About us; PartnersPortfolio & major clientsFAQ, support & contacts
Web EngineeringWeb HostingWeb Consulting

Digital signed e-mail

These message are the basis for electronic invoices and contracts. They use cryptographic methods that ensure the sender is who he claims to be and the message was not changed by others before reaching you.


No signature: production code, without digital signature
Eternal license that allows you the personal or commercial use of the scripts. Only the script usage rights can be transferred, and only by you, and only if you do not charge any money for said transfer (i.e., your clients can use the scripts, but they can't be paying you for them in particular, nor can they transfer rights to third parties). You will receive all PHP files unparagraphed and uncommented (i.e., the files are filtered through "php -w"). The script will have all digital signature code removed.

Production: production code, complete
Based on the "No signature" license, but including the digital signature code.

Development: source code
Based on the "Production" license, but where all PHP files will be completely paragraphed and commented.

Full: full rights
Eternal license with full rights over the code, allowing the transmission of rights, resale and selling access to the script. You will receive all PHP files completely paragraphed and commented.


Sending e-mail
in PHP is a PHP script ready to be included in your code with a simple require_once(), defining a function with the following prototype:

function esx_email( $from, $to, $subject, $msghtml, $msgtxt, $msgxml, $extra, $embed, $attach, $signcert )

This function, similar to PHP's own mail()* (but much more elaborate) will send an HTML/XML message to one or more recipients, with optional embedded images, attachments and digital cryptographic signature.

This is therefore the basis for electronic billing according to current European Union legislation and the sending of HTML messages generated by a Web site or a Webmail system (especially because this function tries to generate some sort of plain text version of the HTML content, if not provided).

esx.emailarray.php is a PHP script bundled with that is used to help creating simple form-to-email scripts. Designed to be included in your code with a simple require_once(), it defines a function with the following prototype:

function esx_emailarray( $to, $subject, $intro, $vars )

This function calls esx_email() sending a report of the variables found in the $vars array. With the default values, you can make a simple form-to-email script by placing in the form's destination PHP file the following code:



Licensed according to one of the options on the left:

No signature





The scripts run on PHP 4.0.0 and above, under both Windows and Unix/Linux platforms. needs PHP 4.0.6 or above if you intend to use the digital signature function. You don't need any particular PHP module installed, but generates messages that are more compatible with very old systems if it has the IMAP module* installed and generates messages that have better chance of crossing anti-spam* systems if PHP's safe-mode is disabled.

The purchase of this software makes you the owner of a ZIP file that will be e-mailed to you, containing:

  • The scripts that may or may not be paragraphed and commented depending on the purchased licensing (see to the left).

You will also be eligible for free e-mail technical support and free upgrades, should you find any flaws that are fixed.


These scripts have been developed under Windows XP and Vista with PHP 5 running under IIS 5 and 6, but have been installed and are in production in LAMP platforms* with PHP 4 and 5 since 2004. is used by this site for automated answers and by Corebase (Cynergi's parent company) for sending electronic invoices.

The scripts are also pre-installed and accessible to hosting clients. They have no known bugs.

During its development special care was taken with the known bugs of each PHP function used, to the many configurations that the scripts could be installed in and to security, preventing SMTP-injection attacks amongst others. The script strictly follows the RFCs 720, 822, 1341, 1766, 2045, 2046, 2047, 2048, 2049, 2076, 2311, 2387, 2557, 2633, 2821, 2822 e 3369 amongst others.

Group Corebase