Änderungen in Modulen lassen sich nicht speichern
Verfasst: Do 5. Mai 2022, 09:37
Hallo,
Nach dem Update habe ich das Problem, dass sich Änderungen in Modulen nicht speichern lassen. Nach dem speichern klicken ist alles wie vorher.
Zum System:
Conlite 2.1.2
PHP 7.4.29
Datenbank 5.5.68-MariaDB
z.B. Bei Speicherversuch des Textmoduls ist in der Errorlog:
Klicke ich bei dem alten Modul xtcDynSpryForm0.9.2 (das eigentliche Ziel meiner Änderung) nur auf speichern ändert sich auch Nichts und es steht in der Errorlog:
Grüße Lars
Nach dem Update habe ich das Problem, dass sich Änderungen in Modulen nicht speichern lassen. Nach dem speichern klicken ist alles wie vorher.
Zum System:
Conlite 2.1.2
PHP 7.4.29
Datenbank 5.5.68-MariaDB
z.B. Bei Speicherversuch des Textmoduls ist in der Errorlog:
Code: Alles auswählen
[05-May-2022 07:23:09 UTC] ConLite DB error: 1064 (You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 's', 'text', "CMS_HTML[6]");
$tpl->generate('templates/text_html.html');
?>', `' at line 1) - info: /conlite/main.php UPDATE `con_mod` SET `name` = 'Text (6)', `output` = '<?php
/**
* $RCSfile$
*
* Description: Output some HTML text
*
* @version 1.0.0
* @author Rudi Bieller
* @copyright four for business AG <www.4fb.de>
*
* {@internal
* created 2008-04-07
* }}
*
* $Id$
*/
if (!isset($tpl) || !is_object($tpl)) {
$tpl = new Template();
}
$tpl->reset();
$tpl->set('s', 'text', "CMS_HTML[6]");
$tpl->generate('templates/text_html.html');
?>', `template` = '', `description` = '<Ihre Modulbeschreibung>
Autor:
Version1', `input` = '', `type` = '', `lastmodified` = '2022-05-05 07:23:09' WHERE idmod = '41'
Code: Alles auswählen
[05-May-2022 07:32:53 UTC] ConLite DB error: 1064 (You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'DOCUMENT_ROOT'] angepasst werden!!!
$CaptchaDir="xtcDynForm/captcha";
$ImgOkNa' at line 1) - info: /conlite/main.php UPDATE `con_mod` SET `name` = '0_xtcDynSpryForm0.9.2', `output` = '<?php
/***********************************************
* Kontaktformular auf Adobe Spry 1.6.1 Basis
*
* Outputbereich
* aktuell werden Textfield, Textarea, Radio, Checkbox, Hidden und Select unterstützt.
*
* Author : Ralf Fleischer
* Copyright : xtended cooperation
* Mail : info@xtended-coperation.de
* Created : 01-05-2008
* Version : 0.9.2
* Modified : 06-07-2008
************************************************/
$fValueOut="CMS_VALUE[10]";
$CaptchaOut="CMS_VALUE[8]";
$PNGFIXOut="CMS_VALUE[9]";
$OutputArtOut="CMS_VALUE[11]";
##########################################################################
################## Verzeichnisse der benötigten Dateien ##################
##########################################################################
$JsDir="xtcDynForm/js";
$CssDir="xtcDynForm/css";
$ImgDir="xtcDynForm/img";
// Pfad für PNGFIX am Ende mit /
// Pfad muss bei Pfadänderungen ebenfalls in der xtcDynForm/iepngfix/iepngfix.htc angepasst werden
$IEPNGFIXDir="xtcDynForm/iepngfix/";
// Pfad bei CaptchaDir änderungen muss auch in der datei xtcDynForm/captcha/captcha.php unter $ttf = $_SERVER['DOCUMENT_ROOT'] angepasst werden!!!
$CaptchaDir="xtcDynForm/captcha";
$ImgOkName="xtc-icon-ok.gif";
$ImgNotOkName="xtc-icon-notok.gif";
##################################################################
################## CSS und JS Dateien einbinden ##################
##################################################################
?>
<iframe id="UploadResponce" name="UploadResponce" src="about:blank" style="display: none; width: 100%;"></iframe>
<div id="SpryContactForm">
<!--<link href="css/example.css" rel="stylesheet" type="text/css" media="screen" />-->
<script src="<?php echo $JsDir; ?>/SpryValidationTextField.js" type="text/javascript"></script>
<script src="<?php echo $JsDir; ?>/SpryValidationTextarea.js" type="text/javascript"></script>
<script src="<?php echo $JsDir; ?>/SpryValidationSelect.js" type="text/javascript"></script>
<script src="<?php echo $JsDir; ?>/SpryValidationRadio.js" type="text/javascript"></script>
<script src="<?php echo $JsDir; ?>/SpryValidationCheckbox.js" type="text/javascript"></script>
<link href="<?php echo $CssDir; ?>/SpryValidationTextarea.css" rel="stylesheet" type="text/css" />
<link href="<?php echo $CssDir; ?>/SpryValidationTextField.css" rel="stylesheet" type="text/css" />
<link href="<?php echo $CssDir; ?>/SpryValidationSelect.css" rel="stylesheet" type="text/css" />
<link href="<?php echo $CssDir; ?>/SpryValidationRadio.css" rel="stylesheet" type="text/css" />
<link href="<?php echo $CssDir; ?>/SpryValidationCheckbox.css" rel="stylesheet" type="text/css" />
<?php
########################################################
################## Contenido Includes ##################
########################################################
cInclude("includes", "functions.general.php");
cInclude("includes", "functions.lang.php");
cInclude("classes", "class.htmlelements.php");
################################################
################## Funktionen ##################
################################################
function xtcCmsHtmlHead($val){
global $db;
global $client;
global $lang;
global $cfg;
global $area_tree;
global $sess;
global $perm;
global $area_rights;
global $item_rights;
global $_SESSION;
global $remakeCatTable;
global $remakeStrTable;
global $auth;
global $tpl;
global $edit;
global $a_content;
global $idartlang;
global $idcat;
global $idart;
/**
* CMS_HTMLHEAD
*/
$tmp = $a_content['CMS_HTMLHEAD'][$val];
$tmp = urldecode($tmp);
if ($edit) {
if ($tmp == "") {
$tmp = " ";
}
$insiteEditingDIV = new cHTMLDiv;
$insiteEditingDIV->setId("HTMLHEAD_".$db->f("idtype")."_".$val);
$insiteEditingDIV->setEvent("Focus", "this.style.border='1px solid #bb5577';");
$insiteEditingDIV->setEvent("Blur", "this.style.border='1px dashed #bfbfbf';");
$insiteEditingDIV->setStyleDefinition("border", "1px dashed #bfbfbf");
$insiteEditingDIV->setStyleDefinition("direction", langGetTextDirection($lang));
$insiteEditingDIV->updateAttributes(array("contentEditable" => "true"));
$insiteEditingDIV->setContent("_REPLACEMENT_");
/* Edit anchor and image */
$editLink = $sess->url("front_content.php?action=10&idcat=$idcat&idart=$idart&idartlang=$idartlang&type=CMS_HTMLHEAD&typenr=$val");
$editAnchor = new cHTMLLink;
$editAnchor->setLink("javascript:setcontent('$idartlang','" . $editLink . "');");
$editButton = new cHTMLImage;
$editButton->setSrc($cfg["path"]["contenido_fullhtml"].$cfg["path"]["images"]."but_edithead.gif");
$editButton->setBorder(0);
$editButton->setStyleDefinition("margin-right", "2px");
$editAnchor->setContent($editButton);
/* Save anchor and image */
$saveAnchor = new cHTMLLink;
$saveAnchor->setLink("javascript:setcontent('$idartlang','0')");
$saveButton = new cHTMLImage;
$saveButton->setSrc($cfg["path"]["contenido_fullhtml"].$cfg["path"]["images"]."but_ok.gif");
$saveButton->setBorder(0);
$saveAnchor->setContent($saveButton);
/* Process for output with echo */
$finalEditButton = $editAnchor->render();
$finalEditingDiv = $insiteEditingDIV->render();
$finalEditingDiv = str_replace("_REPLACEMENT_", $tmp, $finalEditingDiv);
$finalSaveButton = $saveAnchor->render();
return $finalEditingDiv . $finalEditButton . $finalSaveButton;
}else{
$text = new Article($idart, $client, $lang);
$msgText = $text->getContent("CMS_HTMLHEAD", $val);
return $msgText;
}
}
function xtcCmsHtml($val){
global $db;
global $client;
global $lang;
global $cfg;
global $area_tree;
global $sess;
global $perm;
global $area_rights;
global $item_rights;
global $_SESSION;
global $remakeCatTable;
global $remakeStrTable;
global $auth;
global $tpl;
global $edit;
global $a_content;
global $idartlang;
global $idcat;
global $idart;
/**
* CMS_HTML
*/
$tmp = $a_content['CMS_HTML'][$val];
$tmp = urldecode($tmp);
if ($edit) {
if ($tmp == "") {
$tmp = " ";
}
$insiteEditingDIV = new cHTMLDiv;
$insiteEditingDIV->setId("HTML_".$db->f("idtype")."_".$val);
$insiteEditingDIV->setEvent("Focus", "this.style.border='1px solid #bb5577';");
$insiteEditingDIV->setEvent("Blur", "this.style.border='1px dashed #bfbfbf';");
$insiteEditingDIV->setStyleDefinition("border", "1px dashed #bfbfbf");
$insiteEditingDIV->setStyleDefinition("direction", langGetTextDirection($lang));
$insiteEditingDIV->updateAttributes(array("contentEditable" => "true"));
$insiteEditingDIV->setContent("_REPLACEMENT_");
/* Edit anchor and image */
$editLink = $sess->url("front_content.php?action=10&idcat=$idcat&idart=$idart&idartlang=$idartlang&type=CMS_HTML&typenr=$val");
$editAnchor = new cHTMLLink;
$editAnchor->setLink("javascript:setcontent('$idartlang','" . $editLink . "');");
$editButton = new cHTMLImage;
$editButton->setSrc($cfg["path"]["contenido_fullhtml"].$cfg["path"]["images"]."but_edithtml.gif");
$editButton->setBorder(0);
$editButton->setStyleDefinition("margin-right", "2px");
$editAnchor->setContent($editButton);
/* Save anchor and image */
$saveAnchor = new cHTMLLink;
$saveAnchor->setLink("javascript:setcontent('$idartlang','0')");
$saveButton = new cHTMLImage;
$saveButton->setSrc($cfg["path"]["contenido_fullhtml"].$cfg["path"]["images"]."but_ok.gif");
$saveButton->setBorder(0);
$saveAnchor->setContent($saveButton);
/* Process for output with echo */
$finalEditButton = $editAnchor->render();
$finalEditingDiv = $insiteEditingDIV->render();
$finalEditingDiv = str_replace("_REPLACEMENT_", $tmp, $finalEditingDiv);
$finalSaveButton = $saveAnchor->render();
return $finalEditingDiv . $finalEditButton . $finalSaveButton;
}else{
$text = new Article($idart, $client, $lang);
$msgText = $text->getContent("CMS_HTML", $val);
return $msgText;
}
}
#######################################################
################## PNG-IE&-FIX laden ##################
#######################################################
if($PNGFIXOut==1){
echo "<style type=\"text/css\">
img, div { behavior: url(".$IEPNGFIXDir."iepngfix.htc) };
</style>\n";
}
###########################################################
################## idart oder idcat Wahl ##################
###########################################################
if($OutputArtOut=="idart"){
$FormUrl="front_content.php?idart=".$idart;
}else{
$FormUrl="front_content.php?idcat=".$idcat;
}
###################################################################################
################## Contenido Mailversand inkl Captchaüberprüfung ##################
###################################################################################
#Includes
cInclude("classes", "class.phpmailer.php");
if($fValueOut>0){
if(isset($_POST["xtcFormSubmit"])){
if($CaptchaOut==1){
error_reporting(E_ERROR);
session_start();
if(isset($_SESSION['captchaspam']) AND $_POST["sicherheitscode"] == $_SESSION['captchaspam']){
unset($_SESSION['captchaspam']);
}else{
$sendMsgError= mi18n("Der Sicherheitscode ist falsch!")."<br /><br />";
}
}
if(!isset($sendMsgError)){
#No errors, create and send mail
$mail = new phpmailer;
$mail_body = '<html><head></head><body bgcolor="#ffffff"><table cellspacing="0" cellpadding="2" border="0">';
if (is_array($_POST)) {
foreach ($_POST as $key => $value) {
if (($key != 'sicherheitscode')AND($key != 'xtcFormSubmit')AND($key != 'fromthismail')AND($key != 'confirm')) {
if (is_array($value)){$value=implode(",", $value);}
$mail_body .= "<tr><td>$key</td><td>$value</td></tr>";
}
}
}
$mail_body .= '</table></bo'.'dy></html>';
$mail->Host = "localhost";
$mail->IsHTML(true);
#Get mailer from settings
switch (strtolower("CMS_VALUE[4]")) {
case "smtp" :
$mail->IsSMTP();
$host = "CMS_VALUE[5]";
$user = "CMS_VALUE[6]";
$password = "CMS_VALUE[7]";
if (($host != '') && ($user != '') && ($password != '')) {
$mail-> $SMTPAuth = true;
$mail->Host = $host;
$mail->Username = $user;
$mail->Password = $password;
}
break;
case "mail" :
$mail->IsMail();
break;
case "sendmail" :
$mail->IsSendmail();
break;
case "qmail" :
$mail->IsQmail();
break;
default :
}
if(isset($_POST["fromthismail"])){
$fromthismail=$_POST["fromthismail"];
$mail->From = trim($_POST[$fromthismail]);
$mail->FromName = "";
}else{
$mail->From = "CMS_VALUE[0]";
$mail->FromName = "CMS_VALUE[2]";
}
$mail->AddAddress("CMS_VALUE[1]", "");
$mail->Subject = "CMS_VALUE[3]";
$mail->Body = $mail_body;
$mail->WordWrap = 50;
$mail->Send();
if(isset($_POST["confirm"])){
foreach ($_POST["confirm"]as $confomadress){
unset($mail);
$mail = new phpmailer;
$mail->Host = "localhost";
$mail->IsHTML(true);
$mail->IsMail();
$mail->From = "CMS_VALUE[0]";
$mail->FromName = "CMS_VALUE[2]";
$mail->AddAddress($_POST[$confomadress], "");
$mail->Subject = "Bestätigungsemail! "."CMS_VALUE[3]";
$mail->Body = $mail_body;
$mail->WordWrap = 50;
$mail->Send();
}
}
#Display message after mail is sent
#$sendMsgOk = mi18n("Ihr Anliegen wurde uns übermittelt. Vielen Dank!");
#$sendMsgOk = '<script type="text/javascript">alert("' . mi18n("...") . '");</script>';
#$sendMsgOk = '<script type="text/javascript">parent.document.getElementsByTagName("h2")[0].firstChild.data = "' . mi18n("...") . '";</script>';
$sendMsgOk = '<script type="text/javascript">parent.document.getElementById("antwort").innerHTML = "' . mi18n("Ihr Anliegen wurde uns übermittelt. Vielen Dank!") . '";parent.document.getElementById("SpamschutzDiv").style.display = "none";</script>';
}
}
if(isset($sendMsgOk)){
echo $sendMsgOk;
}elseif (isset($sendMsgError)){
##########################################################################
################## Ausgabe bei Fehler und Captcha-Error ##################
##########################################################################
$form_code = '
<form target="UploadResponce" id="form" name="form" method="post" action="' . $FormUrl . '">';
foreach ($_POST AS $a => $b){
if ($a != "sicherheitscode") {
if ($a == "confirm") {
foreach ($b as $c){
$form_code .= '
<input type="hidden" name="confirm[]" value="' . $c . '" />';
}
} else {
if (is_array($b)) {
$b = implode(",", $b);
}
$form_code .= '
<input type="hidden" name="' . $a . '" value="' . $b . '" />';
}
}
}
$form_code .= '
<strong>Spamschutz!</strong><br />Bitte den Code vom Bild noch einmal in das darunter stehende Eingabefenster eintragen!<br /><br />
<span id="SprySicherheitscode">
<img id="Code" src="' . $CaptchaDir . '/captcha.php?x=' . mt_rand(1, 6000) . '" border="0" title="Sicherheitscode"><br />
<input id="sicherheitscode" class="inputform" style="margin-top:6px; margin-bottom:10px;padding: 3px 8px;vertical-align:middle;border-width: 0px;border-style: solid none;width:129px;" type="text" name="sicherheitscode" size="5">
<img src="' . $ImgDir . "/" . $ImgOkName . '" title="Valid" alt="Valid" class="validMsg" border="0"/><img class="novalidMsg" src="' . $ImgDir . "/" . $ImgNotOkName . '" title="NoValid" alt="NoValid" border="0" /><span class="textfieldRequiredMsg">
!</span><span class="textfieldInvalidFormatMsg">Falsches Format.</span><span class="textfieldMinCharsMsg">Bitte exakt die 5 Zeichen!</span><span class="textfieldMaxCharsMsg">Bitte nur die 5 Zeichen!</span></span>
<img src="' . $ImgDir . "/" . $ImgOkName . '" title="Valid" alt="Valid" class="validMsg" border="0"/><img class="novalidMsg" src="' . $ImgDir . "/" . $ImgNotOkName . '" title="NoValid" alt="NoValid" border="0" /><span class="textfieldInvalidFormatMsg">Falsches Format.</span><span class="textfieldMinCharsMsg">Bitte exakt die 5 Zeichen!</span><span class="textfieldMaxCharsMsg">Bitte nur die 5 Zeichen!</span></span>
<br /><br />
<hr class="form" style="float:left;"><span class="contactFormSubmit"><input style="margin-left:22px;" name="xtcFormSubmit" class="submitbutton" type="submit" value="abschicken" /></span>
</form>
<script type="text/javascript">
//<![CDATA[
var SprySicherheitscode = new Spry.Widget.ValidationTextField("SprySicherheitscode","none",{minChars:3,maxChars:5,validateOn:["blur","change"]});
//]]>
</scr\'+\'ipt>';
echo "<script type='text/javascript'>
//<![CDATA[
parent.document.getElementById('antwort').innerHTML = '" . $sendMsgError . str_replace(array("\r\n", "\r", "\n"), ' ', $form_code) . "';
parent.document.getElementById('SpamschutzDiv').style.display = 'none';
//]]>
</script>";
}else{
#########################################################################
################## Zusammenbau der CMS_VALUE Variablen ##################
#########################################################################
if($fValueOut!=""){
for ($y=1;$y<=$fValueOut;$y++){
$fVarTemp=20+$y;
$fVarTempNameOut=$fVarTemp;
$fVarTempRequireOut="r".$fVarTemp;
$fVarTempArtOut="a".$fVarTemp;
$fVarTempCharMin="cmi".$fVarTemp;
$fVarTempCharMax="cma".$fVarTemp;
$fVarTempArtSelectOut="a".$fVarTempArtOut;
$fVarTempFormatOut="form".$fVarTemp;
$fValueTempNameOut="CMS_VALUE[$fVarTempNameOut]";
$fValueTempRequireOut="CMS_VALUE[$fVarTempRequireOut]";
$fValueTempArtOut="CMS_VALUE[$fVarTempArtOut]";
$fValueTempCharMinOut="CMS_VALUE[$fVarTempCharMin]";
$fValueTempCharMaxOut="CMS_VALUE[$fVarTempCharMax]";
$fValueTempArtSelectOut="CMS_VALUE[$fVarTempArtSelectOut]";
$fValueTempFormatOut="CMS_VALUE[$fVarTempFormatOut]";
$FieldsArray[$fValueTempNameOut]=array($fValueTempRequireOut,$fValueTempArtOut,$fValueTempCharMinOut,$fValueTempCharMaxOut,$fValueTempFormatOut);
if(($fValueTempArtOut=="select")OR($fValueTempArtOut=="grpradio")OR($fValueTempArtOut=="grpcheckbox")){
$FieldsOptionArrayName="";
$FieldsOptionArrayString="";
$fValueTempArtOptionOut="a".$fVarTempArtOut;
$fValueTempArtOptionSetOut="CMS_VALUE[$fValueTempArtOptionOut]";
for ($x=1;$x<=$fValueTempArtOptionSetOut;$x++){
$fValueTempArtSelectOptionOut=substr($fValueTempArtOptionOut, 2)+$x;
$fValueTempArtSelectOptionOut=ab.$fValueTempArtSelectOptionOut.$y;
$FieldsOptionArrayName="CMS_VALUE[$fValueTempArtSelectOptionOut]";
$FieldsOptionArrayString.=$FieldsOptionArrayName.",";
}
$FieldsOptionArrayString=substr($FieldsOptionArrayString,0,-1);
$FieldsOptionArrayString2Array=explode(',',$FieldsOptionArrayString);
$FieldsOptionArray[$fValueTempNameOut]= $FieldsOptionArrayString2Array;
}
}
}
$Fields="";
$Fieldshidden="";
$FieldsJava="\n";
foreach($FieldsArray as $Data => $Require){
if($Data!=""){
if($Require[0]=="true"){
##########################################################
################## SpryData Feldernamen ##################
##########################################################
$SpryData="Spry".$Data;
$SpryData = str_replace("-", "", $SpryData);
$SpryData = str_replace("/", "", $SpryData);
$SpryData = str_replace(" ", "", $SpryData);
$SpryData = str_replace(":", "", $SpryData);
$SpryData = str_replace(".", "", $SpryData);
$SpryData = str_replace("*", "", $SpryData);
if($Require[2]==""){$Require[2]=1;}
if($Require[3]==""){$Require[3]=255;}
##########################################################
################## Ausgabe Plichtfelder ##################
##########################################################
if(($Require[1]!="textarea")AND($Require[1]!="select")AND($Require[1]!="oneradio")AND($Require[1]!="grpradio")AND($Require[1]!="onecheckbox")AND($Require[1]!="grpcheckbox")AND($Require[1]!="cmshead")AND($Require[1]!="cmshtml")){
$Fields.="\n\t\t";
$Fields.="<li><span id=\"".$SpryData."\"><label>".$Data."*:</label><input class=\"inputform\" type=\"text\" name=\"".$Data."\" id=\"".$Data."\" />";
$Fields.="<img src=\"".$ImgDir."/".$ImgOkName."\" title=\"Valid\" alt=\"Valid\" class=\"validMsg\" border=\"0\"/>";
$Fields.="<img class=\"novalidMsg\" src=\"".$ImgDir."/".$ImgNotOkName."\" title=\"NoValid\" alt=\"NoValid\" border=\"0\" />";
if($Require[1]=="zip"){$Fields.="<span class=\"textfieldRequiredMsg\">".mi18n("Pflichtfeld nur Zahlen!")."</span>";
// }else{$Fields.="<span class=\"textfieldRequiredMsg\">".mi18n("Pflichtfeld!")."</span>";}
}else{$Fields.="";}
if($Require[1]=="email"){ $Fields.="<span class=\"textfieldInvalidFormatMsg\">".mi18n("Falsches Email-Format.")."</span>";
}elseif($Require[1]=="url"){ $Fields.="<span class=\"textfieldInvalidFormatMsg\">".mi18n("Falsches URL-Format.")."</span>";
}elseif($Require[1]=="int"){ $Fields.="<span class=\"textfieldInvalidFormatMsg\">".mi18n("Bitte nur Zahlen.")."</span>";
}elseif($Require[1]=="zip"){ $Fields.="<span class=\"textfieldInvalidFormatMsg\">".mi18n("Bitte nur die 5 Zahlen")."</span>";
}elseif($Require[1]=="date"){ $Fields.="<span class=\"textfieldInvalidFormatMsg\">".mi18n("Falsches Datum")."</span>";
}elseif($Require[1]=="time"){ $Fields.="<span class=\"textfieldInvalidFormatMsg\">".mi18n("Falsche Uhrzeit")."</span>";
}else{ $Fields.="<span class=\"textfieldInvalidFormatMsg\">".mi18n("Falsches Format.")."</span>";}
//$Fields.="<span class=\"textfieldInvalidFormatMsg\">".mi18n("Falsches Format.")."</span>";
$Fields.="<span class=\"textfieldMinCharsMsg\">".$Require[2].mi18n(" Zeichen mindestens!")."</span>";
$Fields.="<span class=\"textfieldMaxCharsMsg\">".$Require[3].mi18n(" Zeichen maximal!")."</span>";
$Fields.="</span></li>";
if(($Require[1]=="email")AND($Require[2]=="fromthismail")){
$Fieldshidden.="\n\t";
$Fieldshidden.="<input type=\"hidden\" name=\"fromthismail\" id=\"fromthismail\" value=\"".$Data."\" />";
}
if(($Require[1]=="email")AND($Require[3]=="confirm")){
$Fieldshidden.="\n\t";
$Fieldshidden.="<input type=\"hidden\" name=\"confirm[]\" id=\"confirm\" value=\"".$Data."\" />";
}
}
if($Require[1]=="textarea"){
$Fields.="\n\t\t";
$Fields.="<li class=\"textarea\"><span id=\"".$SpryData."\"><label for=\"".$Data."\">".$Data."*:</label>";
$Fields.="<textarea id=\"".$Data."\" rows=\"5\" cols=\"45\" name=\"".$Data."\"></textarea>";
$Fields.="<span id=\"Counterror_mess\">0</span>";
$Fields.="<img src=\"".$ImgDir."/".$ImgOkName."\" title=\"Valid\" alt=\"Valid\" class=\"validMsg\" border=\"0\"/>";
$Fields.="<img class=\"novalidMsg\" src=\"".$ImgDir."/".$ImgNotOkName."\" title=\"NoValid\" alt=\"NoValid\" border=\"0\" />";
$Fields.="<br /><span class=\"textareaRequiredMsg\">".mi18n("Bitte Text eingeben!")."</span>";
$Fields.="<span class=\"textareaMinCharsMsg\">".$Require[2].mi18n(" Zeichen mindestens!")."</span>";
$Fields.="<span class=\"textareaMaxCharsMsg\">".$Require[3].mi18n(" Zeichen maximal!")."</span>";
$Fields.="</span></li>";
}
if($Require[1]=="select"){
$Fields.="\n\t\t";
$Fields.="<li class=\"select\"><span id=\"".$SpryData."\"><label for=\"".$Data."\">".$Data."*:</label>";
$Fields.="<select id=\"".$Data."\" name=\"".$Data."\">";
$Fields.="<option value=\"\">".mi18n("Bitte wählen!")."</option>";
foreach($FieldsOptionArray as $DataSelect => $OptionRequire){
if($DataSelect==$Data){
foreach($OptionRequire as $DataSelect2 => $OptionRequireName){
$Fields.="<option value=\"".$OptionRequireName."\">".$OptionRequireName."</option>";
}
}
}
$Fields.="</select>";
$Fields.="<img src=\"".$ImgDir."/".$ImgOkName."\" title=\"Valid\" alt=\"Valid\" class=\"validMsg\" border=\"0\"/>";
$Fields.="<img class=\"novalidMsg\" src=\"".$ImgDir."/".$ImgNotOkName."\" title=\"NoValid\" alt=\"NoValid\" border=\"0\" />";
$Fields.="<span style=\"display:none\" class=\"selectRequiredMsg\">".mi18n("Bitte auswählen!")."</span>";
$Fields.="</span></li>";
}
if($Require[1]=="oneradio"){
$Fields.="\n\t\t";
$Fields.="<li class=\"oneradio\"><span id=\"".$SpryData."\"><label for=\"".$Data."\">".$Data."*:</label>";
$Fields.="<input type=\"radio\" value=\"".$Data."\" name=\"".$Data."\" id=\"".$Data."\" />";
$Fields.="<img src=\"".$ImgDir."/".$ImgOkName."\" title=\"Valid\" alt=\"Valid\" class=\"validMsg\" border=\"0\"/>";
$Fields.="<img class=\"novalidMsg\" src=\"".$ImgDir."/".$ImgNotOkName."\" title=\"NoValid\" alt=\"NoValid\" border=\"0\" />";
$Fields.="<span class=\"radioRequiredMsg\">".mi18n("Bitte diese Auswahl treffen!")."</span>";
$Fields.="</span></li>";
}
if($Require[1]=="onecheckbox"){
$Fields.="\n\t\t";
$Fields.="<li class=\"onecheckbox\"><span id=\"".$SpryData."\"><label for=\"".$Data."\">".$Data."*:</label>";
$Fields.="<input type=\"checkbox\" value=\"".$Data."\" name=\"".$Data."\" id=\"".$Data."\" />";
$Fields.="<img src=\"".$ImgDir."/".$ImgOkName."\" title=\"Valid\" alt=\"Valid\" class=\"validMsg\" border=\"0\"/>";
$Fields.="<img class=\"novalidMsg\" src=\"".$ImgDir."/".$ImgNotOkName."\" title=\"NoValid\" alt=\"NoValid\" border=\"0\" />";
$Fields.="<span class=\"checkboxRequiredMsg\">".mi18n("Bitte diese Auswahl treffen!")."</span>";
$Fields.="</span></li>";
}
if($Require[1]=="grpradio"){
$Fields.="\n\t\t";
$Fields.="<li class=\"grpradio\"><span id=\"".$SpryData."\"><label for=\"".$Data."\">".$Data."*:</label>";
$Fields.="<span style=\"float:left;\">";
foreach($FieldsOptionArray as $DataSelect => $OptionRequire){
if($DataSelect==$Data){
$count=1;
$countOptionRequire=count($OptionRequire);
foreach($OptionRequire as $DataSelect2 => $OptionRequireName){
$Fields.="<span class=\"grpradio\"><input type=\"radio\" value=\"".$OptionRequireName."\" name=\"".$Data."\" id=\"".$Data."\" />".$OptionRequireName."</span>";
if((is_int($count/$Require[4]))AND($countOptionRequire!=$count)){$Fields.="<br class=\"clear\" />";}
$count++;
}
}
}
$Fields.="<br class=\"clear\" /><img src=\"".$ImgDir."/".$ImgOkName."\" title=\"Valid\" alt=\"Valid\" class=\"validMsg\" border=\"0\"/>";
$Fields.="<img class=\"novalidMsg\" src=\"".$ImgDir."/".$ImgNotOkName."\" title=\"NoValid\" alt=\"NoValid\" border=\"0\" />";
$Fields.="<span class=\"radioRequiredMsg\">".mi18n("Bitte eine Auswahl treffen!")."</span>";
$Fields.="<br /><br /></span>";
$Fields.="</span></li>";
}
if($Require[1]=="grpcheckbox"){
$Fields.="\n\t\t";
$Fields.="<li class=\"grpcheckbox\"><span id=\"".$SpryData."\"><label for=\"".$Data."\">".$Data."*:</label>";
$Fields.="<span style=\"float:left;\">";
foreach($FieldsOptionArray as $DataSelect => $OptionRequire){
if($DataSelect==$Data){
$count=1;
$countOptionRequire=count($OptionRequire);
foreach($OptionRequire as $DataSelect2 => $OptionRequireName){
$Fields.="<span class=\"grpcheckbox\"><input type=\"checkbox\" value=\"".$OptionRequireName."\" name=\"".$Data."[]\" id=\"".$Data."\" />".$OptionRequireName."</span>";
if((is_int($count/$Require[4]))AND($countOptionRequire!=$count)){$Fields.="<br class=\"clear\" />";}
$count++;
}
}
}
$Fields.="<br class=\"clear\" /><img src=\"".$ImgDir."/".$ImgOkName."\" title=\"Valid\" alt=\"Valid\" class=\"validMsg\" border=\"0\"/>";
$Fields.="<img class=\"novalidMsg\" src=\"".$ImgDir."/".$ImgNotOkName."\" title=\"NoValid\" alt=\"NoValid\" border=\"0\" />";
$Fields.="<span class=\"checkboxRequiredMsg\">".mi18n("Bitte eine Auswahl treffen!")."</span>";
$Fields.="<span class=\"checkboxMinSelectionsMsg\">".mi18n("Auswahl min. ist")." ".$Require[2]."</span>";
$Fields.="<span class=\"checkboxMaxSelectionsMsg\">".mi18n("Auswahl max. ist")." ".$Require[3]."</span>";
$Fields.="<br /><br /></span>";
$Fields.="</span></li>";
}
#########################################################
################## SpryData Javascript ##################
#########################################################
if($Require[1]=="textarea"){
$FieldsJava.=" var ".$SpryData." = new Spry.Widget.ValidationTextarea(\"".$SpryData."\", {minChars:".$Require[2].", maxChars:".$Require[3].", useCharacterMasking:false, counterType:\"chars_count\", counterId:\"Counterror_mess\", validateOn:[\"blur\",\"change\"]});\n";
}elseif ($Require[1]=="email"){
$FieldsJava.=" var ".$SpryData." = new Spry.Widget.ValidationTextField(\"".$SpryData."\", \"email\", {validateOn:[\"blur\",\"change\"]});\n";
}elseif ($Require[1]=="url"){
$FieldsJava.=" var ".$SpryData." = new Spry.Widget.ValidationTextField(\"".$SpryData."\", \"url\", {validateOn:[\"blur\",\"change\"]});\n";
}elseif ($Require[1]=="password"){
$FieldsJava.=" var ".$SpryData." = new Spry.Widget.ValidationTextField(\"".$SpryData."\", \"none\", {minChars:".$Require[2].", maxChars:".$Require[3].", validateOn:[\"blur\",\"change\"]});\n";
}elseif ($Require[1]=="zip"){
$FieldsJava.=" var ".$SpryData." = new Spry.Widget.ValidationTextField(\"".$SpryData."\", \"zip_code\", {format:\"zip_us5\", validateOn:[\"blur\",\"change\"], useCharacterMasking:true});\n";
}elseif ($Require[1]=="phone"){
$FieldsJava.=" var ".$SpryData." = new Spry.Widget.ValidationTextField(\"".$SpryData."\", \"phone_number\", {minChars:".$Require[2].", maxChars:".$Require[3].", validateOn:[\"blur\",\"change\"], useCharacterMasking:true});\n";
}elseif ($Require[1]=="int"){
$FieldsJava.=" var ".$SpryData." = new Spry.Widget.ValidationTextField(\"".$SpryData."\", \"integer\", {minChars:".$Require[2].", maxChars:".$Require[3].", validateOn:[\"blur\", \"change\"], useCharacterMasking:false, minValue:\"0\", maxValue:\"999999999999999\"});\n";
}elseif ($Require[1]=="select"){
$FieldsJava.=" var ".$SpryData." = new Spry.Widget.ValidationSelect(\"".$SpryData."\", {validateOn:[\"blur\",\"change\"]});\n";
}elseif ($Require[1]=="oneradio"){
$FieldsJava.=" var ".$SpryData." = new Spry.Widget.ValidationRadio(\"".$SpryData."\", {validateOn:[\"blur\",\"change\"]});";
}elseif ($Require[1]=="grpradio"){
$FieldsJava.=" var ".$SpryData." = new Spry.Widget.ValidationRadio(\"".$SpryData."\", {invalidValue:\"invalid\", emptyValue:\"none\", validateOn:[\"change\", \"blur\"]});";
}elseif ($Require[1]=="onecheckbox"){
$FieldsJava.=" var ".$SpryData." = new Spry.Widget.ValidationCheckbox(\"".$SpryData."\", {validateOn:[\"blur\",\"change\"]});";
}elseif ($Require[1]=="grpcheckbox"){
$FieldsJava.=" var ".$SpryData." = new Spry.Widget.ValidationCheckbox(\"".$SpryData."\", {minSelections:".$Require[2].", maxSelections:".$Require[3].", validateOn:[\"change\", \"blur\"]});";
}elseif ($Require[1]=="date"){
if($Require[4]==""){$Require[4]="dd-mm-yyyy";}
$FieldsJava.=" var ".$SpryData." = new Spry.Widget.ValidationTextField(\"".$SpryData."\", \"date\", {format:\"".$Require[4]."\", hint:\"".$Require[4]."\", validateOn:[\"blur\", \"change\"], useCharacterMasking:true});";
}elseif ($Require[1]=="time"){
if($Require[4]==""){$Require[4]="HH:mm:ss";}
$FieldsJava.=" var ".$SpryData." = new Spry.Widget.ValidationTextField(\"".$SpryData."\", \"time\", {format:\"".$Require[4]."\", hint:\"".$Require[4]."\", validateOn:[\"blur\", \"change\"], useCharacterMasking:true});";
}else{
$FieldsJava.=" var ".$SpryData." = new Spry.Widget.ValidationTextField(\"".$SpryData."\", \"none\", {minChars:".$Require[2].", maxChars:".$Require[3].", validateOn:[\"blur\",\"change\"]});\n";
}
}else{
###############################################################
################## Ausgabe Non-Pflichtfelder ##################
###############################################################
if(($Require[1]!="textarea")AND($Require[1]!="select")AND($Require[1]!="hidden")AND($Require[1]!="oneradio")AND($Require[1]!="onecheckbox")AND($Require[1]!="grpradio")AND($Require[1]!="grpcheckbox")AND($Require[1]!="cmshead")AND($Require[1]!="cmshtml")){
$Fields.="\n\t\t";
$Fields.="<li><label>".$Data.":</label><input class=\"inputform\" type=\"text\" name=\"".$Data."\" id=\"".$Data."\" /></li>";
}
if($Require[1]=="cmshead"){
$Fields.="\n\t\t";
$Fields.="<li class=\"headline\"><h3>".xtcCmsHtmlHead($Data)."</h3></li>";
}
if($Require[1]=="cmshtml"){
$Fields.="\n\t\t";
$Fields.="<li class=\"text\">".xtcCmsHtml($Data)."</li>";
}
if($Require[1]=="textarea"){
$Fields.="\n\t\t";
$Fields.="<li class=\"textarea\"><label for=\"".$Data."\">".$Data.":</label>";
$Fields.="<textarea id=\"".$Data."\" rows=\"5\" cols=\"45\" name=\"".$Data."\"></textarea></li>";
}
if($Require[1]=="select"){
$Fields.="\n\t\t";
$Fields.="<li class=\"select\"><label for=\"".$Data."\">".$Data.":</label>";
$Fields.="<select id=\"".$Data."\" name=\"".$Data."\">";
$Fields.="<option value=\"\">".mi18n("Bitte wählen!")."</option>";
foreach($FieldsOptionArray as $DataSelect => $OptionRequire){
if($DataSelect==$Data){
foreach($OptionRequire as $DataSelect2 => $OptionRequireName){
$Fields.="<option value=\"".$OptionRequireName."\">".$OptionRequireName."</option>";
}
}
}
$Fields.="</select>";
$Fields.="</li>";
}
if($Require[4]==""){$Require[4]=5;}
if($Require[1]=="grpradio"){
$Fields.="\n\t\t";
$Fields.="<li class=\"grpradio\"><label for=\"".$Data."\">".$Data.":</label>";
$Fields.="<span style=\"float:left;\">";
foreach($FieldsOptionArray as $DataSelect => $OptionRequire){
if($DataSelect==$Data){
$count=1;
$countOptionRequire=count($OptionRequire);
foreach($OptionRequire as $DataSelect2 => $OptionRequireName){
$Fields.="<span class=\"grpradio\"><input type=\"radio\" value=\"".$OptionRequireName."\" name=\"".$Data."\" id=\"".$Data."\" />".$OptionRequireName."</span>";
if((is_int($count/$Require[4]))AND($countOptionRequire!=$count)){$Fields.="<br class=\"clear\" />";}
$count++;
}
}
}
$Fields.="</span>";
$Fields.="</li>";
}
if($Require[1]=="grpcheckbox"){
$Fields.="\n\t\t";
$Fields.="<li class=\"grpcheckbox\"><label for=\"".$Data."\">".$Data.":</label>";
$Fields.="<span style=\"float:left;\">";
foreach($FieldsOptionArray as $DataSelect => $OptionRequire){
if($DataSelect==$Data){
$count=1;
$countOptionRequire=count($OptionRequire);
foreach($OptionRequire as $DataSelect2 => $OptionRequireName){
$Fields.="<span class=\"grpcheckbox\"><input type=\"checkbox\" value=\"".$OptionRequireName."\" name=\"".$Data."[]\" id=\"".$Data."\" />".$OptionRequireName."</span>";
if((is_int($count/$Require[4]))AND($countOptionRequire!=$count)){$Fields.="<br class=\"clear\" />";}
$count++;
}
}
}
$Fields.="</span>";
$Fields.="</li>";
}
if($Require[1]=="hidden"){
$Fieldshidden.="\n\t";
$Fieldshidden.="<input type=\"hidden\" name=\"".$Data."\" id=\"".$Data."\" value=\"".$Require[4]."\" />";
}
if($Require[1]=="oneradio"){
$Fields.="\n\t\t";
$Fields.="<li class=\"oneradio\"><label>".$Data.":</label><input type=\"radio\" value=\"".$Data."\" name=\"".$Data."\" id=\"".$Data."\" /></li>";
}
if($Require[1]=="onecheckbox"){
$Fields.="\n\t\t";
$Fields.="<li class=\"onecheckbox\"><label>".$Data.":</label><input type=\"checkbox\" value=\"".$Data."\" name=\"".$Data."\" id=\"".$Data."\" /></li>";
}
}
}
}
#####################################################
################## Ausgabe Captcha ##################
#####################################################
if($CaptchaOut==1){
$CaptchaOutput="\t<strong>".mi18n("Spamschutz!")."</strong><br />\n\t".mi18n("Bitte den Code vom Bild in das darunter stehende Eingabefenster eintragen!")."<br /><br />";
$CaptchaOutput.="\n\t<span id=\"SprySicherheitscode\">";
$CaptchaOutput.="\n\t<img src=\"".$CaptchaDir."/captcha.php\" border=\"0\" title=\"Sicherheitscode\"><br />";
$CaptchaOutput.="\n\t<input class=\"inputform\" id=\"sicherheitscode\" style=\"width:129px;margin-top:6px;\" type=\"text\" name=\"sicherheitscode\" size=\"5\">";
$CaptchaOutput.="\n\t<img src=\"".$ImgDir."/".$ImgOkName."\" title=\"Valid\" alt=\"Valid\" class=\"validMsg\" border=\"0\"/>\n\t<img class=\"novalidMsg\" src=\"".$ImgDir."/".$ImgNotOkName."\" title=\"NoValid\" alt=\"NoValid\" border=\"0\" />\n\t<span class=\"textfieldRequiredMsg\">".mi18n("Pflichtfeld!")."</span>\n\t<span class=\"textfieldInvalidFormatMsg\">".mi18n("Falsches Format.")."</span>\n\t<span class=\"textfieldMinCharsMsg\">".mi18n("Bitte alle Zeichen eingeben!")."</span>\n\t<span class=\"textfieldMaxCharsMsg\">".mi18n("Zuviel Zeichen!")."</span>\n\t</span>";
$FieldsJava.=" var SprySicherheitscode = new Spry.Widget.ValidationTextField(\"SprySicherheitscode\", \"none\", {minChars:3, maxChars:5, validateOn:[\"blur\", \"change\"]});\n";
}
?>
<form target="UploadResponce" id="form" name="form" method="post" action="<?php echo $FormUrl;?>">
<ul><?php echo $Fields."\n"; ?>
</ul>
<?php echo $Fieldshidden; ?>
<div id="SpamschutzDiv">
<?php echo $CaptchaOutput; ?>
<span style="display:none;"><a href="http://www.xtended-cooperation.de" target="_blank">© 2008 by http://www.xtended-cooperation.de</a></span>
<span class="contactFormSubmit"><input class="resetbutton" type="reset" value="<?=mi18n("löschen")?>" /><input name="xtcFormSubmit" class="submitbutton" type="submit" value="<?=mi18n("abschicken")?>" /></span>
</div>
</form>
<div id="antwort" style=""></div>
<?php
}
}
?>
<script type="text/javascript">
<!--<?php echo $FieldsJava; ?>
//-->
</script>
</div>
', `template` = '', `description` = '<Ihre Modulbeschreibung>
Autor:
Version', `input` = '?><?php
/***********************************************
* Kontaktformular auf Adobe Spry 1.6.1 Basis
*
* Inputbereich
* aktuell werden Textfield, Textarea und Select unterstützt.
*
* Author : Ralf Fleischer
* Copyright : xtended cooperation
* Mail : info@xtended-coperation.de
* Created : 01-05-2008
* Version : 0.9.2
* Modified : 06-07-2008
************************************************/
$sSubmitLink = '<a href="javascript:if (document.tplcfgform.send) {document.tplcfgform.send.value = 0}; document.tplcfgform.submit();"><img src="images/submit.gif" /></a>';
$sSubmitOnchange='javascript:if (document.tplcfgform.send) {document.tplcfgform.send.value = 0}; document.tplcfgform.submit();';
$Captcha="CMS_VALUE[8]";
$PNGFIX="CMS_VALUE[9]";
$fValue="CMS_VALUE[10]";
$OutputArt="CMS_VALUE[11]";
if($Captcha==1){$CaptchaTrue=" checked";$CaptchaFalse="";}else{$CaptchaTrue="";$CaptchaFalse=" checked";}
if($PNGFIX==1){$PNGFIXTrue=" checked";$PNGFIXFalse="";}else{$PNGFIXTrue="";$PNGFIXFalse=" checked";}
if($OutputArt=="idart"){$OutputIdArt=" checked";$OutputIdCat="";}else{$OutputIdArt="";$OutputIdCat=" checked";}
?>
<table style="border:1px solid #e2e2e2" cellpadding="0" cellspacing="0" border="0">
<tr>
<td colspan="4" style="background:#f1f1f1;font-weight:bold;border-top:1px solid #e2e2e2;border-bottom:1px solid #e2e2e2;"> <?php echo .........................
.........................
?>
</table>
<script language="JavaScript">
<!--
function dechecked(){
<?php
if(is_array($fromthismailCheckboxnames) && count($fromthismailCheckboxnames) > 0){foreach ($fromthismailCheckboxnames as $checkboxNames){
?>
document.getElementsByName("<?php echo $checkboxNames; ?>")[0].checked = false;
<?php
}
}
?>
}
//-->
</script>
<?php', `type` = '', `lastmodified` = '2022-05-05 07:32:53' WHERE idmod = '38'