HomeHelpTrac

Changeset 15973 for trunk/inc


Ignore:
Timestamp:
02/10/12 22:38:54 (4 months ago)
Author:
Alexander Trofimov
Message:

Editor object + new WYSIWYG editor

Location:
trunk/inc
Files:
2 added
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/inc/classes/BxDolForm.php

    r15907 r15973  
    113113 * - html - display visual editor of certain type, for textarea field type only. 
    114114 *      - 0 - no visual editor, leave textarea field as it is. 
    115  *      - 1 - micro visual editor. 
    116  *      - 2 - default visual editor. 
    117  *      - 3 - mini visual editor. 
     115 *      - 1 - standard(default) visual editor, see @BxDolEditor. 
     116 *      - 2 - full visual editor, see @BxDolEditor. 
     117 *      - 3 - mini visual editor, see @BxDolEditor. 
    118118 * - attrs - serialized array of additional input attributes. 
    119119 * - attrs_tr - serialized array of additional attributes for the whole input row. 
     
    218218 *      - html - use visual editor or not. 
    219219 *          - 0 - no visual editor, leave textarea field as it is. 
    220  *          - 1 - micro visual editor. 
    221  *          - 2 - default visual editor. 
    222  *          - 3 - mini visual editor. 
     220 *          - 1 - standard(default) visual editor, see @BxDolEditor. 
     221 *          - 2 - full visual editor, see @BxDolEditor. 
     222 *          - 3 - mini visual editor, see @BxDolEditor. 
    223223 *      - checker_func 
    224224 *          Can be used here: Length, Preg, Avail  
  • trunk/inc/classes/BxDolLanguages.php

    r15818 r15973  
    8080 
    8181        return (int)$iId; 
     82    } 
     83 
     84    /** 
     85     * It tries to match current language with provided languages array, if nothing is found $sFallbackLanguage is returned. 
     86     * @param $aLangs - array of languages, example: array('ru' => 1, 'kg' => 1); 
     87     * @param $sFallbackLanguage - language to return of nothis is found 
     88     * @return language code string 
     89     */ 
     90    function detectLanguageFromArray($aLangs, $sFallbackLanguage = 'en') { 
     91        return isset($aLangs[$GLOBALS['sCurrentLanguage']]) ? $GLOBALS['sCurrentLanguage'] : $sFallbackLanguage; 
    8292    } 
    8393 
  • trunk/inc/utils.inc.php

    r15887 r15973  
    10351035    if (BX_ESCAPE_STR_APOS == $iQuoteType) { 
    10361036        $aUnits["'"] = "\\'"; 
     1037        $aUnits['<script'] = "<scr' + 'ipt"; 
     1038        $aUnits['</script>'] = "</scr' + 'ipt>"; 
    10371039    } elseif (BX_ESCAPE_STR_QUOTE == $iQuoteType) { 
    10381040        $aUnits['"'] = '\\"'; 
     1041        $aUnits['<script'] = '<scr" + "ipt'; 
     1042        $aUnits['</script>'] = '</scr" + "ipt>'; 
    10391043    } else { 
    10401044        $aUnits['"'] = '&quote;'; 
    10411045        $aUnits["'"] = '&apos;'; 
     1046        $aUnits["<"] = '&lt;'; 
     1047        $aUnits[">"] = '&gt;'; 
    10421048    } 
    10431049    return str_replace(array_keys($aUnits), array_values($aUnits), $mixedInput); 
Note: See TracChangeset for help on using the changeset viewer.