예제 #1
0
 function WYRichTextElement($sN, $bG, $sCSSURL, $bObfuscate)
 {
     parent::WYElement($sN, $bG);
     $this->sEditorPageName = "rich-text.php";
     $this->iEditorWidth = 850;
     $this->iEditorHeight = 620;
     $this->sEditButtonCSSClass = "WebYepRichTextEditButton";
     if ($sCSSURL) {
         $this->oCSSURL = new WYURL($sCSSURL);
         $this->oCSSURL->makeSiteRelative();
     } else {
         $this->oCSSURL = od_nil;
     }
     $this->bObfuscate = $bObfuscate;
     $this->setVersion(WY_RICHTEXT_VERSION);
     if (!isset($this->dContent[WY_DK_CONTENT])) {
         // check whether a Long Text Element with same field name left some data...
         $oLT = new WYLongTextElement($sN, $bG, false);
         if ($oLT->sText() != "") {
             $this->dContent[WY_DK_CONTENT] = $oLT->sDisplay();
         } else {
             $this->dContent[WY_DK_CONTENT] = "";
         }
     }
 }
예제 #2
0
파일: long-text.php 프로젝트: bcneb/WebYep
// WebYep
// (C) Objective Development Software GmbH
// http://www.obdev.at
$webyep_bDocumentPage = false;
$webyep_sIncludePath = "..";
include_once "{$webyep_sIncludePath}/webyep.php";
include_once @webyep_sConfigValue("webyep_sIncludePath") . "/elements/WYLongTextElement.php";
include_once @webyep_sConfigValue("webyep_sIncludePath") . "/lib/WYTextArea.php";
include_once @webyep_sConfigValue("webyep_sIncludePath") . "/lib/WYEditor.php";
$bOK = false;
$sResponse = WYTS("LongTextSaved");
$sHelpFile = "longtext-element.php";
$oEditor = new WYEditor();
$oElement = new WYLongTextElement($oEditor->sFieldName, $oEditor->bGlobal, "");
$oTA = new WYTextArea("TEXT", $oElement->sText());
if ($oEditor->bSave) {
    $oElement->setText($oTA->sText());
    $oElement->save();
    $bOK = true;
} else {
    $sOnLoadScript = 'document.forms[0].TEXT.focus();';
}
$goApp->outputWarningPanels();
// give App a chance to say something
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head>

<title>
<?php 
예제 #3
0
function webyep_sLongTextContent($sFieldName, $bGlobal)
{
    $o = new WYLongTextElement($sFieldName, $bGlobal, false);
    return $o->sText();
}