Menu

#7 Javascript validation

PHP5 - New feature
open-fixed
rules (2)
2
2008-01-03
2007-02-11
Nigel McNie
No

Some kind of framework for javascript validation could be useful, to minimise the invalid data sent over the network. Given that all renderers have to export a function to set an error on a field, and to remove all errors, it may prove not that difficult to implement, but will have to take both the rule and the element it is being applied to into account.

Discussion

  • Nigel McNie

    Nigel McNie - 2008-01-03
    • status: open --> open-fixed
     
  • Nigel McNie

    Nigel McNie - 2008-01-03

    Logged In: YES
    user_id=1083971
    Originator: YES

    Given that jsforms now use AHAH, this is actually solved quite nicely. It's not javascript validation, but data is sent to the server via javascript and the results put in place without forcing a whole page reload. The best part is, you only write the validation rule once - on the server - and it will always work the same.

     

Log in to post a comment.