0

i was trying to create a form , using form builder,but i got an error , and i'm trying to solve it but i can't find the problem. Any one have an idea why i have this error :

Parse Error: syntax error, unexpected '->' (T_OBJECT_OPERATOR) in C:....\SearchFilmForm.php line 13
here is my code 

public function buildForm(FormBuilderInterface $builder, array $options) {
    $builder
            ->add('titre')
           ->add('motcle', 'text', array('label' => 'Mot-clé'));
}

1 Answer 1

2

You need to remove ; after ->add('titre');

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.