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


PHP TextField::FieldHolder方法代碼示例

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


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

示例1: FieldHolder

 public function FieldHolder($properties = array())
 {
     if (Config::inst()->get('MathSpamProtectorField', 'enabled')) {
         return parent::FieldHolder($properties);
     }
     return null;
 }
開發者ID:jelicanin,項目名稱:silverstripe-mathspamprotection,代碼行數:7,代碼來源:MathSpamProtectorField.php

示例2: FieldHolder

 function FieldHolder()
 {
     // TODO Replace with properly extensible view helper system
     $d = Object::create('DateField_View_JQuery', $this);
     $d->onBeforeRender();
     $html = parent::FieldHolder();
     $html = $d->onAfterRender($html);
     return $html;
 }
開發者ID:SustainableCoastlines,項目名稱:loveyourwater,代碼行數:9,代碼來源:DateField.php

示例3: FieldHolder

 public function FieldHolder($properties = array())
 {
     Requirements::javascript(THIRDPARTY_DIR . '/jquery/jquery.js');
     Requirements::css(THIRDPARTY_DIR . '/jquery-ui-themes/smoothness/jquery-ui.css');
     Requirements::javascript(FRAMEWORK_DIR . '/thirdparty/jquery-ui/jquery-ui.js');
     Requirements::javascript('latlongfield/javascript/jquery.locationpicker.js');
     Requirements::javascript('latlongfield/javascript/latlongfield.js');
     Requirements::css('latlongfield/css/latlongfield.css');
     return parent::FieldHolder($properties = array());
 }
開發者ID:helpfulrobot,項目名稱:micschk-silverstripe-latlongfield,代碼行數:10,代碼來源:LatLongField.php

示例4: FieldHolder

 public function FieldHolder($properties = array())
 {
     // load requirements
     Requirements::css('international-phone-number-field/lib/intl-tel-input/build/css/intlTelInput.css');
     Requirements::javascript(THIRDPARTY_DIR . '/jquery/jquery.min.js');
     Requirements::javascript(THIRDPARTY_DIR . '/jquery-validate/jquery.validate.min.js');
     Requirements::combine_files('InternationalPhoneNumberField.js', array('international-phone-number-field/lib/intl-tel-input/build/js/intlTelInput.min.js', 'international-phone-number-field/javascript/init.js'));
     // call parent
     $html = parent::FieldHolder();
     return $html;
 }
開發者ID:helpfulrobot,項目名稱:xini-silverstripe-international-phone-number-field,代碼行數:11,代碼來源:InternationalPhoneNumberField.php

示例5: FieldHolder

    function FieldHolder()
    {
        $holder = parent::FieldHolder();
        $id = $this->id();
        $holder .= <<<JS
\t\t\t<script type="text/javascript">
\t\t\t\tnew Ajax.Autocompleter( '{$id}', '{$id}_Options', '{$this->optionsURL}', { afterUpdateElement : function(el) { if(el.onajaxupdate) { el.onajaxupdate(); } } } );
\t\t\t</script>
JS;
        return $holder;
    }
開發者ID:SustainableCoastlines,項目名稱:loveyourwater,代碼行數:11,代碼來源:AutocompleteTextField.php

示例6: FieldHolder

 public function FieldHolder($properties = array())
 {
     // load requirements
     Requirements::css('international-phone-number-field/lib/intl-tel-input/build/css/intlTelInput.css');
     Requirements::javascript(THIRDPARTY_DIR . '/jquery/jquery.min.js');
     Requirements::javascript(THIRDPARTY_DIR . '/jquery-validate/jquery.validate.min.js');
     Requirements::javascript('international-phone-number-field/lib/intl-tel-input/build/js/intlTelInput.min.js');
     $token = Config::inst()->get('InternationalPhoneNumberField', 'ipinfo_access_token');
     $tokenParameter = $token && strlen($token) > 0 ? '?token=' . $token : '';
     $protocol = $token && strlen($token) > 0 ? 'https' : 'http';
     Requirements::javascriptTemplate('international-phone-number-field/javascript/InternationalPhoneNumberField.js', array('TokenParameter' => $tokenParameter, 'Protocol' => $protocol));
     // call parent
     $html = parent::FieldHolder();
     return $html;
 }
開發者ID:xini,項目名稱:silverstripe-international-phone-number-field,代碼行數:15,代碼來源:InternationalPhoneNumberField.php

示例7: testForTemplate

 /**
  * FieldList::forTemplate() returns a concatenation of FieldHolder values.
  */
 public function testForTemplate()
 {
     $set = new FieldList($a = new TextField('A'), $b = new TextField('B'));
     $this->assertEquals($a->FieldHolder() . $b->FieldHolder(), $set->forTemplate());
 }
開發者ID:normann,項目名稱:sapphire,代碼行數:8,代碼來源:FieldListTest.php

示例8: FieldHolder

 /**
  * @param array $properties
  *
  * @return string
  */
 public function FieldHolder($properties = array())
 {
     Requirements::javascript('//www.addressfinder.co.nz/assets/v2/widget.js');
     Requirements::javascript(THIRDPARTY_DIR . '/jquery/jquery.js');
     Requirements::javascript('addressfinder/javascript/addressfinder.js');
     $properties = array('ApiKey' => Config::inst()->get('AddressFinder', 'api_key'), 'ManualAddressFields' => $this->getManualFields(), 'AddressField' => $this->addressField->Field(), 'ManualToggleField' => $this->manualToggle);
     return parent::FieldHolder($properties);
 }
開發者ID:fullscreeninteractive,項目名稱:silverstripe-addressfinder,代碼行數:13,代碼來源:AddressFinderField.php

示例9: FieldHolder

 /**
  *	Return field holder to the form
  **/
 public function FieldHolder($properties = array())
 {
     return parent::FieldHolder($properties);
 }
開發者ID:helpfulrobot,項目名稱:sam-costigan-linkableobjects,代碼行數:7,代碼來源:DataObjectPicker.php

示例10: FieldHolder

 public function FieldHolder($properties = array())
 {
     if ($this->getConfig('showcalendar')) {
         // TODO Replace with properly extensible view helper system
         $d = DateField_View_JQuery::create($this);
         if (!$d->regionalSettingsExist()) {
             $dateformat = $this->getConfig('dateformat');
             // if no localefile is present, the jQuery DatePicker
             // month- and daynames will default to English, so the date
             // will not pass Zend validatiobn. We provide a fallback
             if (preg_match('/(MMM+)|(EEE+)/', $dateformat)) {
                 $this->setConfig('dateformat', $this->getConfig('datavalueformat'));
             }
         }
         $d->onBeforeRender();
     }
     $html = parent::FieldHolder();
     if (!empty($d)) {
         $html = $d->onAfterRender($html);
     }
     return $html;
 }
開發者ID:ivoba,項目名稱:silverstripe-framework,代碼行數:22,代碼來源:DateField.php

示例11: FieldHolder

 public function FieldHolder()
 {
     $html = "<div class=\"display_anything_field upload_anything_field\">";
     $id = $this->controller->{$this->name}()->getField('ID');
     $migrated_value = $this->controller->{$this->name}()->getField('Migrated');
     $migrator = FALSE;
     if ($this->detect_image_gallery_module && $migrated_value == 0) {
         //display only if we want to detect imagegallery albums and it's not already migrated
         $list = $this->ImageGalleryAlbums();
         if (!empty($list)) {
             $migrator = TRUE;
             $html .= "<div class=\"field_content migrate\">";
             $html .= "<fieldset><h5>Display Anything has detected an ImageGallery album associated with this page</h5>";
             $html .= "<p>Do you wish to migrate it to your new gallery?<p>";
             $html .= "<p>Migration notes:</p><ul>";
             $html .= "<li>The original ImageGallery album will remain untouched.</li>";
             $html .= "<li>Files will be copied alongside current files, this will allow you to remove the old gallery as and when required.</li>";
             $html .= "</ul>";
             $migrate = new DropDownField("{$this->name}[{$id}][MigrateImageGalleryAlbumID]", "Choose an album to migrate images from", $list, '', NULL, '[Do not migrate]');
             $html .= $migrate->FieldHolder();
             $html .= "</fieldset>";
             $html .= "</div>";
         }
     } else {
         if ($migrated_value == 1) {
             $migrator = TRUE;
         }
     }
     $html .= "<div class=\"field_content\">";
     $html .= "<fieldset><h5>Gallery settings and options</h5>";
     $title = new TextField("{$this->name}[{$id}][Title]", "Title", $this->controller->{$this->name}()->getField('Title'));
     $html .= $title->FieldHolder();
     $description = new TextareaField("{$this->name}[{$id}][Description]", "Description", 3, NULL, $this->controller->{$this->name}()->getField('Description'));
     $html .= $description->FieldHolder();
     $visible = new CheckboxField("{$this->name}[{$id}][Visible]", "Publicly Visible", $this->controller->{$this->name}()->getField('Visible') == 1 ? TRUE : FALSE);
     $html .= $visible->FieldHolder();
     if ($migrator && $migrated_value == 1) {
         //only need to show this post migration
         $migrated = new CheckboxField("{$this->name}[{$id}][Migrated]", "Image Gallery migration complete (uncheck and save to display migration options)", TRUE);
         $html .= $migrated->FieldHolder();
     }
     $html .= "</fieldset></div>";
     $html .= "<div class=\"field_content\">";
     $html .= "<fieldset><h5>Gallery Items</h5>";
     if (!empty($id)) {
         $html .= parent::FieldHolder();
     } else {
         $html .= "<div class=\"message\"><p>Gallery items can be uploaded after the gallery is saved for the first time</p></div>";
     }
     $html .= "</fieldset></div>";
     $html .= "</div>";
     return $html;
 }
開發者ID:nyeholt,項目名稱:DisplayAnything,代碼行數:53,代碼來源:DisplayAnythingGalleryField.php

示例12: FieldHolder

 public function FieldHolder($properties = array())
 {
     // TODO Replace with properly extensible view helper system
     $d = DateField_View_JQuery::create($this);
     $d->onBeforeRender();
     $html = parent::FieldHolder();
     $html = $d->onAfterRender($html);
     return $html;
 }
開發者ID:normann,項目名稱:sapphire,代碼行數:9,代碼來源:DateField.php

示例13: SearchField

 function SearchField()
 {
     $field = new TextField('MemberListSearch', _t('MemberList.SEARCH', 'Search'));
     return $field->FieldHolder();
 }
開發者ID:ramziammar,項目名稱:websites,代碼行數:5,代碼來源:MemberList.php


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