Using Multiple Validators in Editor

Using Multiple Validators in Editor

CapamaniaCapamania Posts: 233Questions: 81Answers: 5
edited November 2016 in Editor

I was trying to use multiple Validators. More specific I wanted to add noTags and xss to the existing one's ...

->validator( 'Validate::noTags' )
->validator( 'Validate::xss' )

Yet when adding those two or either one of them like here:

...
Field::inst( 'field1' ),
Field::inst( 'description' )
    ->validator( 'Validate::maxLen', array(
        'max' => 755
    ) )
    ->validator( 'Validate::noTags' ),
Field::inst( 'field3' ),
....

I now get an 'Error' message in the Edit form. I'm using DataTables Editor v1.5.6 (dataTables.editor.min.js)

Replies

  • allanallan Posts: 63,498Questions: 1Answers: 10,471 Site admin

    What is the server returning? Likely it will contain an error message that will describe the problem.

    Allan

This discussion has been closed.