$attributes Block attributes. * @since 0.0.2 */ public function __construct( $attributes ) { $this->slug = 'url'; $this->set_properties( $attributes ); $this->set_input_label( __( 'URL', 'sureforms' ) ); $this->set_error_msg( $attributes, 'srfm_url_block_required_text' ); $this->read_only = ! empty( trim( $this->default ) ) && $attributes['readOnly']; $this->set_unique_slug(); $this->set_field_name( $this->unique_slug ); $this->set_markup_properties( $this->input_label, true ); $this->set_aria_described_by(); $this->set_label_as_placeholder( $this->input_label ); } /** * Render the sureforms url classic styling * * @since 0.0.2 * @return string|bool */ public function markup() { ob_start(); ?>
label_markup ); ?> help_markup ); ?>
aria_described_by ) ? "aria-describedby='" . esc_attr( trim( $this->aria_described_by ) ) . "'" : ''; ?> data-required="data_require_attr ); ?>" aria-required="data_require_attr ); ?>" value="default ); ?>" placeholder_attr ); ?> read_only ? 'readonly' : ''; ?> />
error_msg_markup ); ?>