Support

Account

Home Forums Backend Issues (wp-admin) Echo selected value in quick edit settings

Unread

Echo selected value in quick edit settings

  • Hello, How can I Echo the Selected value in Quick Edit settings? The code below is working when saving, what’s the best way to automatically select the value?

    <label>
    		    <span class="title"><?php _e( 'Country', 'woocommerce' ); ?></span>
    		    <span class="input-text-wrap">
    		    	<select name="_country">
    				<?php
    					$field = apply_filters('acf/load_field', false, 'field_589b6aa133ba4');
    					echo '<option value="">- Select -</option>';
    					foreach ( $field['choices'] as $value ) {
    						echo '<option value="' . esc_attr( $value ) . '">'. $value .'</option>';
    					}
    				?>
    				</select>
    			</span>
    		</label>

    Screenshot below shows that the country field is set to “Albania” but when trying to quick edit that product, the “Country” field is not automatically selected to “Albania”
    https://prnt.sc/jrcosn

Viewing 1 post (of 1 total)

The topic ‘Echo selected value in quick edit settings’ is closed to new replies.