define("TM_TABLE_FRM", $tm_tablePrefix . "frm");
 define("TM_TABLE_FRM_GRP_REF", $tm_tablePrefix . "frm_grp_ref");
 define("TM_TABLE_FRM_S", $tm_tablePrefix . "frm_s");
 define("TM_TABLE_HOST", $tm_tablePrefix . "hosts");
 define("TM_TABLE_BLACKLIST", $tm_tablePrefix . "blacklist");
 define("TM_TABLE_LNK", $tm_tablePrefix . "lnk");
 define("TM_TABLE_LNK_GRP", $tm_tablePrefix . "lnk_grp");
 define("TM_TABLE_LNK_GRP_REF", $tm_tablePrefix . "lnk_grp_ref");
 define("TM_TABLE_LNK_CLICK", $tm_tablePrefix . "lnk_click");
 /***********************************************************/
 //add user
 /***********************************************************/
 if (!DEMO) {
     $pass_hash = md5(TM_SITEID . $name . $pass);
     $CONFIG = new tm_CFG();
     $CONFIG->addUSER(array("siteid" => TM_SITEID, "name" => $name, "passwd" => $pass_hash, "crypt" => crypt($pass, CRYPT_EXT_DES), "email" => $email, "aktiv" => 1, "admin" => 1, "manager" => 1, "style" => "default", "lang" => $lang, "startpage" => "Welcome", "expert" => 0));
 }
 //demo
 $MESSAGE .= "<br>" . sprintf(___("Benutzer '%s' wurde angelegt."), $name);
 /***********************************************************/
 //add config
 /***********************************************************/
 if (!DEMO) {
     //insert config
     $CONFIG->addCFG(array("siteid" => TM_SITEID, "name" => "Tellmatic_0", "lang" => $lang, "style" => "default", "notify_mail" => $email, "notify_subscribe" => 0, "notify_unsubscribe" => 0, "max_mails_retry" => 5, "emailcheck_intern" => 2, "emailcheck_subscribe" => 2, "emailcheck_sendit" => 1, "emailcheck_checkit" => 3, "check_version" => 1, "rcpt_name" => "Newsletter", "track_image" => '_blank', "unsubscribe_use_captcha" => 0, "unsubscribe_digits_captcha" => 4, "unsubscribe_sendmail" => 1, "unsubscribe_action" => "unsubscribe", "unsubscribe_host" => 1, "checkit_limit" => 25, "checkit_from_email" => '', "checkit_adr_reset_error" => 1, "checkit_adr_reset_status" => 1, "bounceit_limit" => 10, "bounceit_host" => 0, "bounceit_action" => 'auto', "bounceit_search" => 'header', "bounceit_filter_to" => 0, "bounceit_filter_to_email" => '', "proof" => 1, "proof_url" => 'http://proof.tellmatic.org', "proof_trigger" => 10, "proof_pc" => 10));
     //add mailservers, use default settings for config and create smtp/pop3 host entries...
     $HOSTS = new tm_HOST();
     //add smtp host
     $Add_Host = $HOSTS->addHost(array("siteid" => TM_SITEID, "name" => "default smtp", "aktiv" => 1, "host" => $smtp_host, "port" => $smtp_port, "options" => "novalidate-cert", "smtp_auth" => $smtp_auth, "smtp_domain" => $smtp_domain, "smtp_ssl" => 0, "smtp_max_piped_rcpt" => 1, "type" => "smtp", "user" => $smtp_user, "pass" => $smtp_pass, "max_mails_atonce" => 25, "max_mails_bcc" => 1, "sender_name" => "Tellmatic", "sender_email" => $email, "return_mail" => $email, "reply_to" => $email, "delay" => 100000));
     //make default smtp host!
     $HOSTS->setHostStd($Add_Host[1]);
예제 #2
0
 }
 if (empty($email)) {
     $check = false;
     $_MAIN_MESSAGE .= "<br>" . ___("Die E-Mail-Adresse darf nicht leer sein.");
 }
 //email auf gueltigkeit pruefen
 $check_mail = checkEmailAdr($email, $EMailcheck_Intern);
 if (!$check_mail[0]) {
     $check = false;
     $_MAIN_MESSAGE .= "<br>" . ___("Die E-Mail-Adresse ist nicht gültig.") . " " . $check_mail[1];
 }
 if ($check) {
     if (!DEMO) {
         $USERS = new tm_CFG();
         $pass_hash = md5(TM_SITEID . $name . $pass);
         $USERS->addUSER(array("siteid" => TM_SITEID, "name" => $name, "passwd" => $pass_hash, "crypt" => crypt($pass, CRYPT_EXT_DES), "email" => $email, "aktiv" => $aktiv, "admin" => $admin, "manager" => $manager, "startpage" => $startpage, "style" => $style, "lang" => $lang, "expert" => 0));
         //neue .htpasswd schreiben!
         $tm_htpasswd = "";
         //userliste holen
         $ALL_USERS = $USERS->getUsers();
         $uc = count($ALL_USERS);
         for ($ucc = 0; $ucc < $uc; $ucc++) {
             $tm_htpasswd .= $ALL_USERS[$ucc]['name'] . ":" . $ALL_USERS[$ucc]['crypt'] . "\n";
         }
         //for
         //neue .htpasswd schreiben!
         write_file(TM_INCLUDEPATH, ".htpasswd", $tm_htpasswd);
         unset($ALL_USERS);
     }
     //demo
     $_MAIN_MESSAGE .= "<br>" . sprintf(___("Neuer Benutzer %s wurde angelegt."), "'<b>" . display($name) . "</b>'");