Version: current

     1 <?php
     2 /**
     3  * Read-only field to display a non-editable value with a label.
     4  * Consider using an {@link LabelField} if you just need a label-less
     5  * value display.
     6  *
     7  * @package forms
     8  * @subpackage fields-basic
     9  */
    10 class ReadonlyField extends FormField {
    11
    12     protected $readonly = true;
    13
    14     function performReadonlyTransformation() {
    15         return clone $this;
    16     }
    17 }
    18 ?>

[Raise a SilverStripe Framework issue/bug](https://github.com/silverstripe/silverstripe-framework/issues/new)
- [Raise a SilverStripe CMS issue/bug](https://github.com/silverstripe/silverstripe-cms/issues/new)
- Please use the Silverstripe Forums to ask development related questions. -