need help with "new Input"

Open to all! Ask other shopowners for help.
Post Reply
rupruprup
Member
Posts: 44
Joined: Thu Nov 05, 2020 7:39 pm
Phoenix Version: v1.0.9.10
Has thanked: 6 times
Been thanked: 3 times

need help with "new Input"

Post by rupruprup »

Hello all

old : tep_draw_input_field('name', $XXXX, 'required aria-required="true" id="inputFromName" placeholder="' . ENTRY_NAME_TEXT . '"');

new: (new Input('name', [ 'id' => 'inputFromName', 'placeholder' => ENTRY_NAME_TEXT]))->require(), FORM_REQUIRED_INPUT;

how is the $XXXX to add into the new form to get same result ?

thanks in advance
Ralph


Join The Code Co-op to get access to your library in the Code Co-op Forum
User avatar
burt
Core Team
Posts: 4551
Joined: Tue Oct 29, 2019 9:37 am
Phoenix Version: v1.1.0.8
Has thanked: 252 times
Been thanked: 412 times

Re: need help with "new Input"

Post by burt »

(new Input('name', ['value' => $xxxx, 'id' => 'inputFromName', 'placeholder' => ENTRY_NAME_TEXT]))->require(), FORM_REQUIRED_INPUT;
I am not here to build for you.
I am here to build with you. Let's help each other.


Join The Code Co-op to get access to your library in the Code Co-op Forum
Post Reply