type
2 years ago
div-row.php
2 years ago
div-rows.php
2 years ago
form.php
2 years ago
list-row.php
2 years ago
list-rows.php
2 years ago
p-row.php
2 years ago
p-rows.php
2 years ago
table-row.php
2 years ago
table-rows.php
2 years ago
list-row.php
40 lines
| 1 | <?php |
| 2 | // Don't load directly. |
| 3 | if ( ! defined( 'ABSPATH' ) ) { |
| 4 | die( '-1' ); |
| 5 | } |
| 6 | |
| 7 | /** |
| 8 | * @var Pods $pod |
| 9 | * @var mixed $id |
| 10 | * @var string $field_prefix |
| 11 | * @var \Pods\Whatsit\Field $field |
| 12 | * @var string $row_classes |
| 13 | * @var mixed $value |
| 14 | * @var string|null $heading_tag |
| 15 | */ |
| 16 | ?> |
| 17 | <li class="pods-field__container pods-field-option <?php echo esc_attr( $row_classes ); ?>" |
| 18 | style="<?php echo esc_attr( 'hidden' == $field['type'] ? 'display:none;' : '' ); ?>"> |
| 19 | <?php if ( 'heading' === $field['type'] ) : ?> |
| 20 | <?php $heading_tag = pods_v( $field['type'] . '_tag', $field, isset( $heading_tag ) ? $heading_tag : 'h2', true ); ?> |
| 21 | <<?php echo esc_html( sanitize_key( $heading_tag ) ); ?> |
| 22 | class="pods-form-ui-heading pods-form-ui-heading-<?php echo esc_attr( $field['name'] ); ?>" |
| 23 | id="heading-<?php echo esc_attr( $field['name'] ); ?>"> |
| 24 | <?php echo esc_html( $field['label'] ); ?> |
| 25 | </<?php echo esc_html( sanitize_key( $heading_tag ) ); ?>> |
| 26 | <?php echo PodsForm::comment( $field['name'], pods_v( 'description', $field ), $field ); ?> |
| 27 | <?php elseif ( 'html' === $field['type'] && 1 === (int) $field['html_no_label'] ) : ?> |
| 28 | <?php echo PodsForm::field( $field['name'], $value, $field['type'], $field, $pod, $id ); ?> |
| 29 | <?php else : ?> |
| 30 | <div class="pods-field-label"> |
| 31 | <?php echo PodsForm::label( $field['name'], $field['label'], pods_v( 'help', $field ), $field ); ?> |
| 32 | </div> |
| 33 | |
| 34 | <div class="pods-field-input"> |
| 35 | <?php echo PodsForm::field( $field['name'], $value, $field['type'], $field, $pod, $pod->id() ); ?> |
| 36 | <?php echo PodsForm::comment( $field['name'], null, $field ); ?> |
| 37 | </div> |
| 38 | <?php endif; ?> |
| 39 | </li> |
| 40 |