<?php

/*
to view the initer :
echo $this->showIniter();
or better way
uncomment in this file the line : //$content.=$this->showIniter();
*/
$this->initer['mainsubtitle'] = "Example";
//use $this->initer['varname'] to update and $this->varname to use or print
//if your update doesnt work, add a $this->reloadIniter(); line after your changements
$instancePage = new Example($this->initer);
$content = "";
//$content.=$this->showIniter();
$content .= $instancePage->content_loader();
$this->tpl->remplir_template("content", $content);
//example mail
if ($this->includer->include_pratikclass("mail")) {
    $instanceMail = new PratikMail($this->initer);
    $data = array("objet" => "Test", "texte" => "Text test");
    $instanceMail->construct_mail("custom", $data);
    //,"mainmailcontent","mainmail");
    //$resultsentmail=$instanceMail->send_mail($instanceMail->objet,array("*****@*****.**"));
    //print_r($resultsentmail);
}
<?php

/*
var dispos:
$tabpost (array des valeur envoyées en POST)
$tabparam (array des params supplémentaires)
$preform (array du preform si besoin)
*/
//prepare contenu du mail
$dataprepared = "";
foreach ($tabpost as $idlineform => $lineform) {
    $dataprepared[] = array();
    $dataprepared[count($dataprepared) - 1]['label'] = $idlineform;
    $dataprepared[count($dataprepared) - 1]['champs'] = $lineform;
}
//action send mail
if ($this->includer->include_pratikclass("mail")) {
    $instanceMail = new PratikMail($this->initer);
    $data = array("objet" => "Data saved", "texte" => "Data saved ! ", "tabdata" => $dataprepared);
    $instanceMail->construct_mail("custom", $data, "datamailcontent");
    //,"mainmail");
    $resultsentmail = $instanceMail->send_mail($instanceMail->objet, array($_SESSION['mail_user']));
}