# give/4.18.0/src/Form/LegacyConsumer/templates/base.html.php

GiveWP – Donation Plugin and Fundraising Platform, version 4.18.0. 29 lines.

- Page: https://pluginprobe.com/plugins/give/4.18.0/code/src/Form/LegacyConsumer/templates/base.html.php
- Raw: https://pluginprobe.com/plugins/give/4.18.0/raw/src/Form/LegacyConsumer/templates/base.html.php
- Modified: 2023-01-18T19:19:38+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/give/4.18.0/code/src/Form/LegacyConsumer/templates/base.html.php#L10-L20`.

```php
<?php
/** @var \Give\Framework\FieldsAPI\Text $field */ ?>
<?php
/** @var string $typeAttribute */ ?>
<?php
/** @var string $fieldIdAttribute */ ?>
<input
    type="<?php
    echo $typeAttribute; ?>"
    name="<?php
    echo $field->getName(); ?>"
    placeholder="<?php
    echo $field->getPlaceholder(); ?>"
    id="<?php
    echo $fieldIdAttribute; ?>"
    value="<?php
    echo $field->getDefaultValue(); ?>"
    <?php
    echo $field->isRequired() ? 'required' : ''; ?>
    <?php
    echo $field->isReadOnly() ? 'readonly' : ''; ?>

    <?php
    if( method_exists( $field, 'getMaxLength' ) ) {
        echo ($maxLength = $field->getMaxLength()) ? "maxlength=\"$maxLength\"" : '';
    }
    ?>
>

```
