uawdijnntqw1x1x1
IP : 216.73.216.107
Hostname : toronto-dev2
Kernel : Linux toronto-dev2 4.15.0-213-generic #224-Ubuntu SMP Mon Jun 19 13:30:12 UTC 2023 x86_64
Disable Function : None :)
OS : Linux
PATH:
/
srv
/
users
/
craft4
/
apps
/
.
/
craft4-newsite-space
/
.
/
vendor
/
craftcms
/
cms
/
src
/
fields
/
RadioButtons.php
/
/
<?php /** * @link https://craftcms.com/ * @copyright Copyright (c) Pixel & Tonic, Inc. * @license https://craftcms.github.io/license/ */ namespace craft\fields; use Craft; use craft\base\ElementInterface; use craft\base\SortableFieldInterface; use craft\fields\data\SingleOptionFieldData; /** * RadioButtons represents a Radio Buttons field. * * @author Pixel & Tonic, Inc. <support@pixelandtonic.com> * @since 3.0.0 */ class RadioButtons extends BaseOptionsField implements SortableFieldInterface { /** * @inheritdoc */ public static function displayName(): string { return Craft::t('app', 'Radio Buttons'); } /** * @inheritdoc */ public static function valueType(): string { return sprintf('\\%s', SingleOptionFieldData::class); } /** * @inheritdoc */ public function useFieldset(): bool { return true; } /** * @inheritdoc */ protected function inputHtml(mixed $value, ?ElementInterface $element = null): string { /** @var SingleOptionFieldData $value */ if (!$value->valid) { Craft::$app->getView()->setInitialDeltaValue($this->handle, null); } return Craft::$app->getView()->renderTemplate('_includes/forms/radioGroup.twig', [ 'describedBy' => $this->describedBy, 'name' => $this->handle, 'value' => $this->encodeValue($value), 'options' => $this->translatedOptions(true, $value, $element), ]); } /** * @inheritdoc */ protected function optionsSettingLabel(): string { return Craft::t('app', 'Radio Button Options'); } }
/srv/users/craft4/apps/./craft4-newsite-space/./vendor/craftcms/cms/src/fields/RadioButtons.php