function includeScripts($aConf) { parent::includeScripts($aConf); $sAbsName = $this->getAbsName(); $sInitScript = <<<INITSCRIPT \t\t \t\ttry { \t\t\tFormidable.f("{$this->oForm->formid}").o("{$sAbsName}").oSWFUpload = new SWFUpload( \t\t\t\tFormidable.f("{$this->oForm->formid}").o("{$sAbsName}").config.swfupload_config \t\t\t); \t\t} catch(e) { \t\t\t//alert("SWFUpload exception !!!" + e.name + ":" + e.message); \t\t\t//throw(e); \t\t} INITSCRIPT; $sUninitScript = <<<UNINITSCRIPT \t\t \t\ttry { \t\t\tFormidable.f("{$this->oForm->formid}").o("{$sAbsName}").destroy(); \t\t} catch(e) { \t\t\t//alert("SWFUpload exception !!!" + e.name + ":" + e.message); \t\t\t//throw(e); \t\t} \t\t\t UNINITSCRIPT; # the SWFUpload initalization is made post-init # as when rendered in an ajax context in a modalbox, # the HTML is available *after* init tasks # as the modalbox HTML is added to the page using after init tasks ! $this->sys_attachPostInitTask($sInitScript, "Post-init SWFUPLOAD", $this->_getElementHtmlId()); $this->sys_attachPreUninitTask($sUninitScript, "Post-init SWFUPLOAD", $this->_getElementHtmlId()); }
function cleanStatics() { parent::cleanStatics(); unset($this->aStatics["targetdir"]); unset($this->aStatics["targetfile"]); $this->aStatics["targetdir"] = $this->aEmptyStatics["targetdir"]; $this->aStatics["targetfile"] = $this->aEmptyStatics["targetfile"]; }
function _hasThrown($sEvent, $sWhen = FALSE) { if ($sEvent === "click") { // handling special click server event on rdt_submit // special because has to work without javascript return $this->hasSubmitted(); } return parent::_hasThrown($sEvent, $sWhen); }
function getValue() { $sValue = parent::getValue(); if ($this->defaultFalse("/convertfromrte/")) { $aParseFunc["parseFunc."] = $GLOBALS["TSFE"]->tmpl->setup["lib."]["parseFunc_RTE."]; $sValue = $this->oForm->cObj->stdWrap($sValue, $aParseFunc); } return $sValue; }
function includeScripts($aConf = array()) { parent::includeScripts($aConf); $sAbsName = $this->getAbsName(); $sInitScript = <<<INITSCRIPT \t\t\tFormidable.f("{$this->oForm->formid}").o("{$sAbsName}").init(); INITSCRIPT; # initalization is made post-init # as when rendered in an ajax context in a modalbox, # the HTML is available *after* init tasks # as the modalbox HTML is added to the page using after init tasks ! $this->oForm->attachPostInitTask($sInitScript, "Post-init JSTREE initialization", $this->_getElementHtmlId()); }
function includeScripts($aLibs) { $sAbsName = $this->getAbsName(); $sInitScript = <<<INITSCRIPT \t\ttry { \t\t\tif(Formidable.f("{$this->oForm->formid}").o("{$sAbsName}").domNode()) { \t\t\t\tFormidable.f("{$this->oForm->formid}").o("{$sAbsName}").oTabPanel = new Control.Tabs( \t\t\t\t\tFormidable.f("{$this->oForm->formid}").o("{$sAbsName}").domNode(), \t\t\t\t\tFormidable.f("{$this->oForm->formid}").o("{$sAbsName}").config.libconfig \t\t\t\t); \t\t\t} \t\t} catch(e) {} \t\t INITSCRIPT; $this->sys_attachPostInitTask($sInitScript, "Post-init TABPANEL", $this->_getElementHtmlId()); parent::includeScripts($aLibs); }
function _getAddInputParamsArray() { $aAddParams = parent::_getAddInputParamsArray(); if (($mUseMap = $this->_navConf("/usemap")) !== FALSE) { if (tx_ameosformidable::isRunneable($mUseMap)) { $mUseMap = $this->callRunneable($mUseMap); } if ($mUseMap !== FALSE) { $aAddParams[] = " usemap=\"" . $mUseMap . "\" "; } } if (($mAlt = $this->_navConf("/alt")) !== FALSE) { if (tx_ameosformidable::isRunneable($mAlt)) { $mAlt = $this->callRunneable($mAlt); } if ($mAlt !== FALSE) { $aAddParams[] = " alt=\"" . $mAlt . "\" "; } } reset($aAddParams); return $aAddParams; }
function includeScripts($aConf = array()) { parent::includeScripts($aConf); $sAbsName = $this->_getElementHtmlIdWithoutFormId(); $sInitScript = ''; if ($this->isFlexgridLister()) { if (($sGridClass = $this->_navConf('/flexigridconfiguration/class')) !== FALSE) { $sJson = $this->generateFlexigridJson(); $sInitScript .= <<<INITSCRIPT \t\t\t\t\t\$(".{$sGridClass}").flexigrid({$sJson}); INITSCRIPT; } else { $this->oForm->mayday("RENDERLET LISTER - flexgrid lister need a class."); } } $sInitScript .= <<<INITSCRIPT \t\t\tFormidable.f("{$this->oForm->formid}").o("{$sAbsName}").init(); INITSCRIPT; # initalization is made post-init # as when rendered in an ajax context in a modalbox, # the HTML is available *after* init tasks # as the modalbox HTML is added to the page using after init tasks ! $this->oForm->attachPostInitTask($sInitScript, "Post-init LISTER initialization", $this->_getElementHtmlId()); }
function getValue() { return intval(parent::getValue()); }
function includeScripts($aConf = array()) { $this->oForm->oJs->jquery_loadUiPlugin("slider"); parent::includeScripts($aConf); }
function _getElementHtmlId($sId = FALSE) { $sRes = parent::_getElementHtmlId($sId); $aData =& $this->oForm->oDataHandler->_getListData(); if (!empty($aData)) { $sRes .= AMEOSFORMIDABLE_NESTED_SEPARATOR_BEGIN . $aData["uid"] . AMEOSFORMIDABLE_NESTED_SEPARATOR_END; } return $sRes; }
function _getAddInputParamsArray() { $aAddParams = parent::_getAddInputParamsArray(); if (($sTarget = $this->_navConf("/target")) !== FALSE) { $aAddParams[] = " target=\"" . $sTarget . "\" "; } reset($aAddParams); return $aAddParams; }
function includeScripts($aConf = array()) { parent::includeScripts($aConf); $sAbsName = $this->_getElementHtmlIdWithoutFormId(); $sInitScript = <<<INITSCRIPT \t\t\tFormidable.f("{$this->oForm->formid}").o("{$sAbsName}").init(); INITSCRIPT; $this->oForm->attachPostInitTask($sInitScript, "Post-init ADVSEARCHFORM initialization", $this->_getElementHtmlId()); }
function getValue($aItems = FALSE) { $sSetValue = parent::getValue(); if (is_array($sSetValue)) { $sSetValue = array_diff($sSetValue, array('')); } if (!is_array($sSetValue) && trim($sSetValue) !== "") { return $sSetValue; } elseif (is_array($sSetValue) && !empty($sSetValue) && !(sizeof($sSetValue) == 1 && trim($sSetValue[0]) == '')) { return $sSetValue; } if ($aItems == FALSE) { $aItems = $this->_getItems(); } return ""; }
function _init(&$oForm, $aElement, $aObjectType, $sXPath) { parent::_init($oForm, $aElement, $aObjectType, $sXPath); $this->_initDescendants(); // early init (meaning before removing unprocessed rdts) }
function _getStyleArray() { $aStyles = parent::_getStyleArray(); $iWidth = $this->getPxWidth(); if ($iWidth !== FALSE) { $iStepWidth = round($iWidth * $this->getPercent() / 100, 0); $aStyles["width"] = $iStepWidth . "px"; } if ($this->defaultTrue("/usedefaultstyle")) { if (!array_key_exists("border", $aStyles) && !array_key_exists("border-width", $aStyles)) { $aStyles["border-width"] = "2px"; } if (!array_key_exists("border", $aStyles) && !array_key_exists("border-color", $aStyles)) { $aStyles["border-color"] = "silver"; } if (!array_key_exists("border", $aStyles) && !array_key_exists("border-style", $aStyles)) { $aStyles["border-style"] = "solid"; } if (!array_key_exists("text-align", $aStyles)) { $aStyles["text-align"] = "center"; } if (!array_key_exists("overflow", $aStyles)) { $aStyles["overflow"] = "hidden"; } } reset($aStyles); return $aStyles; }
function getValue() { $mValue = parent::getValue(); if ($this->_allowManualEdition() && $this->shouldConvertToTimestamp()) { if (!$this->_emptyFormValue($mValue)) { return $this->__date2tstamp($mValue, $this->_getFormat(), $this->_getTimeFormat()); } return ""; } return $mValue; }
function doAfterListRender(&$oListObject) { #debug($this->_getElementHtmlId(), "doBeforeListRender"); parent::doAfterListRender($oListObject); if ($this->hasChilds()) { $aChildKeys = array_keys($this->aChilds); reset($aChildKeys); while (list(, $sKey) = each($aChildKeys)) { $this->aChilds[$sKey]->doAfterListRender($oListObject); } } }
function setValue($mValue) { if (!is_array($mValue)) { if (empty($mValue)) { $mValue = array(); } else { $mValue = array($mValue); } } if (array_key_exists('value', $mValue)) { $mValue = $mValue['value']; } parent::setValue($mValue); }