Wird ein CMS_HTML o. CMS_HTMLHEAD direckt im Browser editiert, werden diese Daten nicht gespeichert wenn man z.B. ein CMS_TEXT zum editieren öffnet. Es wird aber gespeichert wenn ich anstelle des CMS_TEXT ein CMS_HTML zum editieren öffne.
Entweder ich speicher alle Daten wenn ich in einen Editor gehen oder nicht. Ansonsten ist es für Kunden nicht Transparent.
Ein UPDATE für Beides im CMS_TEXT[] von mir realisiert worden:
Code: Alles auswählen
/**
* CMS_TEXT
*/
cInclude("classes", "class.htmlelements.php");
cInclude("includes", "functions.lang.php");
$tmp = $a_content["CMS_TEXT"][$val];
$tmp = urldecode($tmp);
$tmp = htmlspecialchars($tmp);
$tmp = nl2br($tmp);
$tmp = str_replace("'", "\'", $tmp);
$tmp = str_replace("\$",'\\\$',$tmp);
$tmp = str_replace("<br />","<br>", $tmp);
if ($edit) {
/* Edit anchor and image */
$editLink = $sess->url("front_content.php?action=10&idcat=$idcat&idart=$idart&idartlang=$idartlang&type=CMS_TEXT&typenr=$val&lang=$lang");
$editAnchor = new cHTMLLink;
$editAnchor->setLink("javascript:setcontent('$idartlang','".$editLink."');");
// ZUM SPEICHERN DER DATEN JS setcontent()
$editButton = new cHTMLImage;
$editButton->setSrc($cfg["path"]["contenido_fullhtml"].$cfg["path"]["images"]."but_edittext.gif");
$editButton->setBorder(0);
$editButton->setStyleDefinition("margin-right", "2px");
$editAnchor->setContent($editButton);
/* Process for output with echo */
$finalEditButton = $editAnchor->render();
$finalEditButton = AddSlashes(AddSlashes($finalEditButton));
$finalEditButton = str_replace("\\\'","'",$finalEditButton);
$tmp = $tmp.$finalEditButton;
}
else {
// INTEGRATION DER SESSION-ID FÜR GET
$tmp_link = $sess->url("front_content.php");
$tmp = str_replace("front_content.php?", "front_content.php", $tmp);
$tmp = str_replace("front_content.php", $tmp_link."&", $tmp);
}
PLUS:
Frontend-Session via GET
siehe: http://www.contenido.org/forum/viewtopi ... 873#115873