Exemplo n.º 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] = "";
         }
     }
 }
Exemplo n.º 2
0
 function webyep_longText($sFieldName, $bGlobal, $deprecated1 = "", $bHide = false)
 {
     global $goApp;
     $o = new WYLongTextElement($sFieldName, $bGlobal, $bHide);
     $s = $o->sDisplay();
     if ($goApp->bEditMode) {
         echo $o->sEditButtonHTML("edit-button-long-text.gif");
         if (!$s) {
             $s = $o->sName;
         }
     }
     echo $s;
 }