| [ Index ] |
PHP Cross Reference of Limb3 |
[Summary view] [Print] [Text view]
1 <?php 2 /* 3 * Limb PHP Framework 4 * 5 * @link http://limb-project.com 6 * @copyright Copyright © 2004-2007 BIT(http://bit-creative.com) 7 * @license LGPL http://www.gnu.org/copyleft/lesser.html 8 */ 9 require_once('limb/wact/src/tags/form/control.inc.php'); 10 define('LIMB_WYSIWYG_DIR', dirname(__FILE__) . '/../../../'); 11 12 /** 13 * @tag richedit,wysiwyg 14 * @package wysiwyg 15 * @version $Id: wysiwyg.tag.php 6009 2007-06-21 09:19:18Z serega $ 16 */ 17 class lmbWysiwygTag extends WactControlTag 18 { 19 var $runtimeComponentName = 'lmbWysiwygComponent'; 20 var $runtimeIncludeFile = 'limb/wysiwyg/src/template/components/lmbWysiwygComponent.class.php'; 21 var $ini_file_name = 'wysiwyg.ini'; 22 var $profile; 23 24 function prepare() 25 { 26 $this->determineComponent(); 27 } 28 29 function determineComponent() 30 { 31 $ini = lmbToolkit :: instance()->getConf($this->ini_file_name); 32 33 if(($this->profile = $this->getAttribute('profile')) == '' && 34 ($this->profile = $ini->getOption('profile')) == '') 35 { 36 $this->profile = null; 37 return; 38 } 39 40 if($ini->getOption('runtimeIncludeFile', $this->profile)) 41 $this->runtimeIncludeFile = $ini->getOption('runtimeIncludeFile', $this->profile); 42 if($ini->getOption('runtimeComponentName', $this->profile)) 43 $this->runtimeComponentName = $ini->getOption('runtimeComponentName', $this->profile); 44 45 } 46 47 protected function _renderOpenTag($code_writer) 48 { 49 } 50 51 protected function _renderCloseTag($code_writer) 52 { 53 } 54 55 function generateTagContent($code) 56 { 57 if(isset($this->attributeNodes['name']) && !$this->attributeNodes['name']->isConstant()) 58 { 59 $code->writePhp($this->getComponentRefCode() . '->setAttribute("name", '); 60 $code->writePhp($this->attributeNodes['name']->generateExpression($code)); 61 $code->writePhp(');' . "\n"); 62 } 63 $code->writePhp($this->getComponentRefCode() . '->initWysiwyg("'. $this->ini_file_name . '","'.$this->profile.'" );' . "\n"); 64 $code->writePhp($this->getComponentRefCode() . '->renderContents();' . "\n"); 65 } 66 } 67 ?>
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
| Generated: Thu Aug 21 04:38:04 2008 | Cross-referenced by PHPXref 0.7 |