當前位置: 首頁>>代碼示例>>PHP>>正文


PHP HtmlEditorField::__construct方法代碼示例

本文整理匯總了PHP中HtmlEditorField::__construct方法的典型用法代碼示例。如果您正苦於以下問題:PHP HtmlEditorField::__construct方法的具體用法?PHP HtmlEditorField::__construct怎麽用?PHP HtmlEditorField::__construct使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在HtmlEditorField的用法示例。


在下文中一共展示了HtmlEditorField::__construct方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: __construct

 public function __construct($name, $title = null, $value = '')
 {
     parent::__construct($name, $title, $value);
     $this->rows = 5;
     // The .htmleditor class enables TinyMCE
     $this->addExtraClass('htmleditor');
 }
開發者ID:helpfulrobot,項目名稱:i-lateral-silverstripe-carousel,代碼行數:7,代碼來源:CarouselPage.php

示例2: __construct

 /**
  * @see TextareaField::__construct()
  */
 public function __construct($name, $title = null, $value = '')
 {
     parent::__construct($name, $title, $value);
     $this->extraClasses[] = 'htmleditor';
     self::include_js();
 }
開發者ID:chitosystems,項目名稱:silverstripe-retina-images,代碼行數:9,代碼來源:RetinaImage.php

示例3: __construct

 /**
  * @see TextareaField::__construct()
  */
 public function __construct($name, $title = null, $value = '')
 {
     parent::__construct($name, $title, $value);
     $this->extraClasses[] = 'htmleditor';
     HtmlEditorConfig::require_js();
     // when updating the resampled image, find the orginal.
     // ideally this would live server side in HtmlEditorField_Toolbar(), however
     // injecting it with a function would be overkill.
     Requirements::customScript("\n(function(\$) {\n\t\$.entwine('ss', function(\$) {\n\t\t\$('form.htmleditorfield-form').entwine({\n\t\t\tupdateFromEditor: function() {\t\t\n\t\t\t\tvar self = this, node = this.getSelection();\n\t\t\t\tif(node.is('img')) {\n\t\t\t\t\tmyfixurl = node.data('url') || node.attr('src');\n\t\t\t\t\tmyfixurl = myfixurl.replace('-10x', '');\n\t\t\t\t\tmyfixurl = myfixurl.replace(/_resampled\\/(.+)\\//, '');\n\t\t\t\t\tnode.attr('src', myfixurl);\n\t\t\t\t}\n\t\t\t\tthis.redraw();\n\t\t\t\tthis._super();\n\t\t\t},\n\t\t});\n\t});\n})(jQuery);");
 }
開發者ID:otago,項目名稱:silverstripe-retinaimages,代碼行數:13,代碼來源:RetinaImage.php

示例4: __construct

 public function __construct($name, $title = null, $value = '')
 {
     parent::__construct($name, $title, $value);
     HtmlEditorConfig::require_js();
     Requirements::customScript("ssTinyMceConfig.mode = 'specific_textareas';ssTinyMceConfig.editor_selector='frontendhtmleditor';tinyMCE.init(ssTinyMceConfig);");
 }
開發者ID:helpfulrobot,項目名稱:andrelohmann-silverstripe-legacyfields,代碼行數:6,代碼來源:FrontendHtmlEditorField.php


注:本文中的HtmlEditorField::__construct方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。