removed edit page in settings + manage subscription update
This commit is contained in:
@ -25,18 +25,24 @@ class Radio extends Base {
|
||||
|
||||
$html .= 'name="'.$field_name.'" ';
|
||||
|
||||
$html .= 'value="'.esc_attr($option['value']).'" ';
|
||||
if(is_array($option['value'])) {
|
||||
$value = key($option['value']);
|
||||
$label = reset($option['value']);
|
||||
} else {
|
||||
$value = $option['value'];
|
||||
$label = $option['value'];
|
||||
}
|
||||
|
||||
$html .= 'value="'.esc_attr($value).'" ';
|
||||
|
||||
$html .= (
|
||||
(isset($option['is_checked']) && $option['is_checked'])
|
||||
||
|
||||
(self::getFieldValue($block) === $option['value'])
|
||||
(self::getFieldValue($block) === $value)
|
||||
) ? 'checked="checked"' : '';
|
||||
|
||||
$html .= $field_validation;
|
||||
|
||||
$html .= ' /> '.esc_attr($option['value']);
|
||||
|
||||
$html .= ' /> '.esc_attr($label);
|
||||
$html .= '</label>';
|
||||
}
|
||||
|
||||
|
@ -18,7 +18,12 @@ class Select extends Base {
|
||||
$html .= '<option value="">'.static::getFieldLabel($block).'</option>';
|
||||
}
|
||||
|
||||
foreach($block['params']['values'] as $option) {
|
||||
$options = (!empty($block['params']['values'])
|
||||
? $block['params']['values']
|
||||
: array()
|
||||
);
|
||||
|
||||
foreach($options as $option) {
|
||||
$is_selected = (
|
||||
(isset($option['is_checked']) && $option['is_checked'])
|
||||
||
|
||||
|
Reference in New Issue
Block a user