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


PHP TextareaField::Field方法代碼示例

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


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

示例1: Field

 function Field($properties = array())
 {
     Requirements::css(MARKDOWN_BASE . '/css/MarkdownEditorField.css');
     Requirements::javascript(MARKDOWN_BASE . '/thirdparty/ace/src-min-noconflict/ace.js');
     Requirements::javascript(MARKDOWN_BASE . '/js/MarkdownEditorField.js');
     return parent::Field($properties);
 }
開發者ID:helpfulrobot,項目名稱:silverstripers-silverstripe-markdown,代碼行數:7,代碼來源:MarkdownEditorField.php

示例2: testTextEncoding

 /**
  * Quick smoke test to ensure that text is being encoded properly.
  */
 function testTextEncoding()
 {
     $inputText = "These are some unicodes: äöü";
     $field = new TextareaField("Test", "Test");
     $field->setValue($inputText);
     $this->assertContains('These are some unicodes: äöü', $field->Field());
 }
開發者ID:nomidi,項目名稱:sapphire,代碼行數:10,代碼來源:TextareaFieldTest.php

示例3: Field

 /**
  * @return string
  */
 function Field($properties = array())
 {
     self::include_js($this->markupType, $this->includeCallback);
     $settings = ucfirst($this->markupType);
     // add JS
     Requirements::customScript('jQuery().ready(function () { jQuery("#' . $this->id() . '").markItUp(my' . $settings . 'Settings)});');
     return parent::Field($properties);
 }
開發者ID:nyeholt,項目名稱:silverstripe-simplewiki,代碼行數:11,代碼來源:MarkItUpField.php

示例4: Field

 function Field()
 {
     Requirements::javascript(THIRDPARTY_DIR . "/jquery/jquery.js");
     Requirements::javascript("dataobject_manager/code/simple_wysiwyg_field/javascript/htmlbox.min.js");
     Requirements::javascript("dataobject_manager/code/simple_wysiwyg_field/javascript/xhtml.js");
     Requirements::customScript($this->buildJS());
     return parent::Field();
 }
開發者ID:SustainableCoastlines,項目名稱:loveyourwater,代碼行數:8,代碼來源:SimpleWysiwygField.php

示例5: Field

 public function Field($properties = array())
 {
     $this->addExtraClass('stacked');
     Requirements::javascript(POSTMARK_RELATIVE_PATH . '/thirdparty/quill/quill.min.js');
     Requirements::javascript(POSTMARK_RELATIVE_PATH . '/javascript/QuillEditorField.js');
     Requirements::css(POSTMARK_RELATIVE_PATH . '/thirdparty/quill/quill.snow.css');
     Requirements::css(POSTMARK_RELATIVE_PATH . '/css/QuillEditorField.css');
     return parent::Field($properties);
 }
開發者ID:bueckl,項目名稱:postmarkedapp,代碼行數:9,代碼來源:QuillEditorField.php

示例6: getColumnContent

 /**
  * HTML for the column, content of the <td> element.
  *
  * @param  GridField $gridField
  * @param  DataObject $record - Record displayed in this row
  * @param  string $columnName
  * @return string - HTML for the column. Return NULL to skip.
  */
 public function getColumnContent($gridField, $record, $columnName)
 {
     $field = new TextareaField('MetaDescription');
     $value = $gridField->getDataFieldValue($record, $columnName);
     $value = $this->formatValue($gridField, $record, $columnName, $value);
     $field->setName($this->getFieldName($field->getName(), $gridField, $record));
     $field->setValue($value);
     return $field->Field() . $this->getErrorMessages();
 }
開發者ID:helpfulrobot,項目名稱:littlegiant-silverstripe-seo-editor,代碼行數:17,代碼來源:SEOEditorMetaDescriptionColumn.php

示例7: Field

 function Field($properties = array())
 {
     $acePath = $this->getAcePath();
     Requirements::javascript($acePath . "ace.js");
     Requirements::javascript($acePath . "mode-" . $this->getMode() . ".js");
     //	Requirements::javascript($acePath . "worker-" . $this->getMode() . ".js");
     Requirements::javascript("codeeditorfield/javascript/CodeEditorField.js");
     Requirements::css("codeeditorfield/css/CodeEditorField.css");
     return parent::Field($properties);
 }
開發者ID:helpfulrobot,項目名稱:nathancox-codeeditorfield,代碼行數:10,代碼來源:CodeEditorField.php

示例8: Field

 /**
  * @return string
  */
 public function Field($properties = array())
 {
     // mark up broken links
     $value = Injector::inst()->create('HTMLValue', $this->value);
     if ($links = $value->getElementsByTagName('a')) {
         foreach ($links as $link) {
             $matches = array();
             if (preg_match('/\\[sitetree_link(?:\\s*|%20|,)?id=([0-9]+)\\]/i', $link->getAttribute('href'), $matches)) {
                 if (!DataObject::get_by_id('SiteTree', $matches[1])) {
                     $class = $link->getAttribute('class');
                     $link->setAttribute('class', $class ? "{$class} ss-broken" : 'ss-broken');
                 }
             }
             if (preg_match('/\\[file_link(?:\\s*|%20|,)?id=([0-9]+)\\]/i', $link->getAttribute('href'), $matches)) {
                 if (!DataObject::get_by_id('File', $matches[1])) {
                     $class = $link->getAttribute('class');
                     $link->setAttribute('class', $class ? "{$class} ss-broken" : 'ss-broken');
                 }
             }
         }
     }
     $properties['Value'] = htmlentities($value->getContent(), ENT_COMPAT, 'UTF-8');
     return parent::Field($properties);
 }
開發者ID:hemant-chakka,項目名稱:awss,代碼行數:27,代碼來源:HtmlEditorField.php

示例9: Field

 public function Field($properties = array())
 {
     // Include requirements
     $this->getEditorConfig()->init();
     return parent::Field($properties);
 }
開發者ID:jacobbuck,項目名稱:silverstripe-framework,代碼行數:6,代碼來源:HTMLEditorField.php

示例10: Field

 public function Field($properties = array())
 {
     Requirements::javascript(FORM_EXTRAS_PATH . '/javascript/expandable/jquery.expandable.js');
     Requirements::javascript(FORM_EXTRAS_PATH . '/javascript/ExpandableTextareaField.js');
     return parent::Field($properties);
 }
開發者ID:lekoala,項目名稱:silverstripe-form-extras,代碼行數:6,代碼來源:ExpandableTextareaField.php

示例11: Field

 /**
  * @return string
  */
 public function Field($properties = array())
 {
     // Before rendering our field, require our custom script
     Requirements::javascriptTemplate("trumbowyg-htmleditor/javascript/trumbowyg-init.js", array('ID' => $this->ID(), "Buttons" => $this->getButtonsJS()));
     return parent::Field($properties);
 }
開發者ID:i-lateral,項目名稱:silverstripe-trumbowyg-htmleditor,代碼行數:9,代碼來源:TrumbowygHTMLEditorField.php

示例12: testTextEncoding

	/**
	 * Quick smoke test to ensure that text is being encoded properly.
	 */
	function testTextEncoding() {
		$inputText = "This is my <text>These are some unicodes: äöü&<>";
		$field = new TextareaField("Test", "Test");
		$field->setValue($inputText);
		$this->assertContains('This is my &lt;text&gt;These are some unicodes: &auml;&ouml;&uuml;&amp;&lt;&gt;', $field->Field());
	}
開發者ID:redema,項目名稱:sapphire,代碼行數:9,代碼來源:TextareaFieldTest.php

示例13: Field

 public function Field($properties = array())
 {
     return parent::Field($properties);
 }
開發者ID:helpfulrobot,項目名稱:chitosystems-bootstrap-fields,代碼行數:4,代碼來源:BootstrapTextareaField.php

示例14: Field

 function Field()
 {
     Requirements::javascript($this->BaseHref() . "jsparty/jquery/jquery.js");
     Requirements::javascript($this->BaseHref() . "dataobject_manager/code/simple_tinymce_field/javascript/tiny_mce/jquery.tinymce.js");
     Requirements::javascript($this->BaseHref() . "dataobject_manager/code/simple_tinymce_field/javascript/tiny_mce/tiny_mce.js");
     Requirements::customScript($this->buildJS());
     return parent::Field();
 }
開發者ID:racontemoi,項目名稱:shibuichi,代碼行數:8,代碼來源:SimpleTinyMCEField.php

示例15: Field

 function Field($properties = array())
 {
     Requirements::javascript(FORM_EXTRAS_PATH . '/javascript/LimitedTextareaField.js');
     return parent::Field($properties);
 }
開發者ID:helpfulrobot,項目名稱:lekoala-silverstripe-form-extras,代碼行數:5,代碼來源:LimitedTextareaField.php


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