0, 'field' => '', 'label' => '', 'separator' => '', 'prefix' => '', 'sufix' => '', 'placeholder' => '', 'multy_value_separator' => '', 'style' => '', 'css_class' => '', 'css_id' => '', 'padding_top' => '', 'padding_bottom' => '', 'link_text' => '', 'visibility' => 'public' ) ) ); if ( $visibility == 'public' || is_user_logged_in() ) { if ( ( ! is_singular() && $post_id === 0 ) || empty( $field ) ) { return ''; } if ( $post_id === 0 ) { $post_id = get_the_ID(); } $field_value = get_field( $field, $post_id ) ?: $placeholder; if ( ! empty( $field_value ) ) { $field_output = awv_prepare_field_value( $field_value, $atts ); if ( ! empty( $field_output ) ) { $css_id = ! empty( $css_id ) ? 'id="' . $css_id . '"' : ''; $label = ! empty( $label ) ? '' . $label . '' : ''; $style = ''; $style .= ! empty( $padding_top ) && is_numeric( $padding_top ) ? 'padding-top:' . $padding_top . 'px;' : ''; $style .= ! empty( $padding_bottom ) && is_numeric( $padding_bottom ) ? 'padding-bottom:' . $padding_bottom . 'px;' : ''; $style = ! empty( $style ) ? 'style=' . $style . '' : ''; return '