in reply to Re: Separation of Presentation and Application/Business Logic
in thread the trend of the presentation layer driving application logic

That's certainly true, but at the risk of getting off-topic, you'd be... living dangerously, let's say... to trust the form to check your data integrity. So you're likely going to be checking it server side anyway.

Personally, I like to see that included in forms, not for any application logic or dubious security reasons, but for the general level of ill will you'll generate by silently and ruthlessly obliterating the input from valid users. Preventing such behavior strikes me as a goal of both the presentation and business logics anyway.

  • Comment on Re: Re: Separation of Presentation and Application/Business Logic

Replies are listed 'Best First'.
Re: Re: Re: Separation of Presentation and Application/Business Logic
by hakkr (Chaplain) on Nov 04, 2003 at 14:12 UTC
    Thats the trouble with html it's not always just about appearance. You know I'm sure I read somewhere that forms will be extended to include validation using xml schmas can't quite remember.

    I do recognise that javascript and html validation usually creeps into templates and thus puts logic and code into them.

    You can usually use file includes to extract most of the javascript out though and generate form fields server side using CGI.pm.

    I know maxsize annoys me if it truncates my form input so yep you should usually tell the user on client side with javascript.