yform = $yform; $this->field_id = $field_id; $this->label = $label; $this->page_type_recommended = $page_type_recommended; $this->page_type_specific = $page_type_specific; } /** * Renders a div for the react application to mount to, and hidden inputs where * the app should store it's value so they will be properly saved when the form * is submitted. * * @return void */ public function render() { $this->yform->hidden( $this->field_id, $this->field_id ); printf( '
', esc_attr( $this->field_id ), esc_attr( $this->label ), esc_attr( $this->page_type_recommended ), esc_attr( $this->page_type_specific ) ); } }