# merchant/2.3.1/admin/classes/admin-options/fields/image-picker/template.php

Product Labels, Quick View, Buy Now, Pre-Orders, Frequently Bought Together &amp; More for WooCommerce – Merchant, version 2.3.1. 34 lines.

- Page: https://pluginprobe.com/plugins/merchant/2.3.1/code/admin/classes/admin-options/fields/image-picker/template.php
- Raw: https://pluginprobe.com/plugins/merchant/2.3.1/raw/admin/classes/admin-options/fields/image-picker/template.php
- Modified: 2026-08-13T11:45:08+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/merchant/2.3.1/code/admin/classes/admin-options/fields/image-picker/template.php#L10-L20`.

```php
<?php
/**
 * Template: Image Picker field.
 *
 * @var array<string, mixed>  $settings  Field configuration.
 * @var mixed  $value     Current saved value.
 * @var string $module_id Module ID.
 *
 * @package Merchant
 * @since   2.2.5
 */

if ( ! defined( 'ABSPATH' ) ) {
	exit;
}

?>
<div class="merchant-image-picker">
	<?php if ( ! empty( $settings['options'] ) ) :
		foreach ( $settings['options'] as $key => $option ) : ?>
			<label>
				<input type="radio" name="merchant[<?php echo esc_attr( $settings['id'] ); ?>]" value="<?php echo esc_attr( $key ); ?>" <?php checked( $value, $key, true ); ?>/>
				<?php if ( isset( $option['image'] ) ) { ?>
					<img src="<?php echo esc_url( $option['image'] ) ?>" alt="">
				<?php } ?>
				<?php if ( isset( $option['title'] ) ) { ?>
					<span class="tool-tip-text"><?php echo esc_html( $option['title'] ) ?></span>
				<?php } ?>
			</label>
		<?php endforeach;
	endif; ?>
</div>
<?php

```
