Пример #1
0
include_once @webyep_sConfigValue("webyep_sIncludePath") . "/lib/WYTextField.php";
include_once @webyep_sConfigValue("webyep_sIncludePath") . "/lib/WYEditor.php";
$bOK = false;
$sResponse = WYTS("ShortTextSaved");
$sHelpFile = "shorttext-element.php";
$oEditor = new WYEditor();
$oTF = new WYTextField("TEXT");
$oTF->setWidth($goApp->bIsiPhone ? 40 : 40);
$oTF->setAttribute("id", "inputTextField");
$oElement = new WYShortTextElement($oEditor->sFieldName, $oEditor->bGlobal);
if ($oEditor->bSave) {
    $oElement->setText($oTF->sValue());
    $oElement->save();
    $bOK = true;
} else {
    $oTF->setValue($oElement->sText());
    $sOnLoadScript = 'document.forms[0].TEXT.focus();';
}
$goApp->outputWarningPanels();
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head>

<title>
<?php 
WYTSD("ShortTextEditorTitle", true);
?>
</title>
<?php 
echo $goApp->sCharsetMetatag();
?>
Пример #2
0
                }
                $oFU->deleteTmpFile();
            } else {
                $sResponse = $oFU->sErrorMessage();
            }
        } else {
            // maybe only URL changed
            $oElement->setLinkURL($oTFURL->sValue());
            $oElement->setAltText($oTFAltText->sValue());
            $oElement->save();
            $sResponse = WYTS("ImageSaved");
            $bOK = true;
        }
    } else {
        $oTFURL->setValue($oElement->sLinkURL());
        $oTFAltText->setValue($oElement->sAltText());
    }
}
$goApp->outputWarningPanels();
// give App a chance to say something
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head>

<title>
<?php 
WYTSD("ImageEditorTitle", true);
?>
</title>
<?php 
echo $goApp->sCharsetMetatag();