コード例 #1
0
ファイル: wysiwyg.tag.php プロジェクト: snowjobgit/limb
 protected function _determineWidget()
 {
     $component_info = $this->_helper->getMacroWidgetInfo();
     $this->widget_include_file = $component_info['file'];
     $this->widget_class_name = $component_info['class'];
     $this->html_tag = 'wysiwyg';
     $this->has_closing_tag = false;
     $this->set('profile_name', $this->_helper->getProfileName());
 }
コード例 #2
0
 function generateTagContent($code)
 {
     if (isset($this->attributeNodes['name']) && !$this->attributeNodes['name']->isConstant()) {
         $code->writePhp($this->getComponentRefCode() . '->setAttribute("name", ');
         $code->writePhp($this->attributeNodes['name']->generateExpression($code));
         $code->writePhp(');' . "\n");
     }
     $code->writePhp($this->getComponentRefCode() . '->initWysiwyg("' . $this->_helper->getProfileName() . '" );' . "\n");
     $code->writePhp($this->getComponentRefCode() . '->renderContents();' . "\n");
 }
コード例 #3
0
 function testSetGetProfileName()
 {
     $this->assertEqual($this->_helper->getProfileName(), 'foo_profile');
     $this->_helper->setProfileName('bar_profile');
     $this->assertEqual($this->_helper->getProfileName(), 'bar_profile');
 }