Source for file DBMS_FIELD_WYMEDITOR.phpclass
Documentation is available at DBMS_FIELD_WYMEDITOR.phpclass
* openCSP class file DBMS_FIELD_WYMEDITOR.phpclass
* @project Open CSP-Management
* @author Peter Krebs <pitlinz@users.sourceforge.net>
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
* @version $Id: DBMS_FIELD_WYMEDITOR.phpclass,v 1.3 2008/10/12 14:55:25 pitlinz Exp $
// ---------------------------------------------------------
// ---------------------------------------------------------
* openCSP class DBMS_FIELD_WYMEDITOR
* @project Open CSP-Management
* @author Peter Krebs <pitlinz@users.sourceforge.net>
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
* @version $Id: DBMS_FIELD_WYMEDITOR.phpclass,v 1.3 2008/10/12 14:55:25 pitlinz Exp $
// ---------------------------------------------------------------------------
// ---------------------------------------------------------------------------
* @constant string CLASS_SRC_FILE
// ---------------------------------------------------------------------------
// ---------------------------------------------------------------------------
/*** class vars ------------------------------------------------------ */
/*** class methods --------------------------------------------------- */
// ---------------------------------------------------------------------------
// ---------------------------------------------------------------------------
/*** compostion --------------------------------------------------- */
/*** attributes -------------------------------------------------- */
* source file of the class
* @var string $classSrcFile
* @var bool $isSearchable overwrite parent set to FALSE
* @var bool $allowHTML overwrite parent set to TRUE
* @var bool $nlToBr overwrite parent set to FALSE
// ---------------------------------------------------------------------------
// ---------------------------------------------------------------------------
// ---------------------------------------------------------------------------
// ---------------------------------------------------------------------------
* returns the html code for a editable formular element
* @param mixed $aValue the value to set
* @param string $nameAdd append something to name like "[VALUE]" for search forms
function getInputTag($aValue,$arrName=
"DBVAL",$nameAdd=
"",$debug=
FALSE) {
$tag .=
"name=\"$arrName".
"[".
$this->myName.
"]\" ";
$tag .=
"id=\"".
$this->getDOMId().
"\" ";
// --------------------------------------------------------
// --------------------------------------------------------
* returns an array of jOCSP/jQuery Modules which are required
* $arr_ret[]="script url";
if ($debug) echoDebugMethod(__FILE__
,get_classe($this),"DBMS_FIELD::jOCSP_getRequiredModules()");
$arr_ret =
parent::jOCSP_getRequiredModules($debug);
'CLASS' =>
'jQuery.fn.wymeditor',
'SRC' =>
OCSP_OBJ::getConf('SYSTEMURL').
"javascript/jquery/wymeditor/jquery.wymeditor.js"
* returns additional object elements of the field object
* array definition: [elemName] = value
* NOTE: do not js_escapte value this is done when building the json object
$arr_ret =
parent::jOCSP_getAdditonalFieldObjElems($debug);
//$arr_ret['debug'] = "true";
$arr_ret['wym'] =
'null';
$arr_ret['init'] =
"function() {
postInit: function(wym) {
jOCSP.getFormByHash('" .
$this->getControll()->jOCSP_getfrmHash() .
"').wym=wym;
if (typeof(WYMeditor.WymClassSafari) == 'undefined')
var html_doc = document.getElementsByTagName('head').item(0);
var jscript = document.createElement('script');
jscript.setAttribute('language', 'javascript');
jscript.setAttribute('type', 'text/javascript');
jscript.setAttribute('src', '" .
OCSP_OBJ::getConf('SYSTEMURL').
"javascript/jquery/wymeditor/jquery.wymeditor.js');
jscript.onload = function() {
jQuery('#" .
$this->getDOMId() .
"').wymeditor(options);
html_doc.appendChild(jscript);
jQuery('#" .
$this->getDOMId() .
"').wymeditor(options);
$arr_ret['beforeSubmit'] =
"function() {jOCSP.getFormByHash('" .
$this->getControll()->jOCSP_getfrmHash() .
"').wym.update();}";
Documentation generated on Thu, 08 Jan 2009 17:43:14 +0100 by phpDocumentor 1.4.0a2