Brett Sanger wrote: > Quite often I have applications that have a "read" mode and an "update" > mode. This means a template for Update that is filled in via > HTML::FillInForm, and another template for Read that is filled in via my > templating engine (Template Toolkit in my case) > > I've found myself spending extra cycles making sure the Read templates > are updated whenever the Update templates are. Laziness demands that I > consider how to automate that. > > Now I could write a simple wrapper that generates the HTML for both, > but that requires that all of my templates look the same, which is very > much not the case here, various apps are highly worked over by the > designer. I'm thinking more in terms of HTML::FillInForm, > except that I'd need to provide some sort of tagging to mark which > visual elements are associated with which data elements. Likewise > field-level control would have to exist, as not all fields would be > displayed. > > Perhaps it would involve so much configuration work as to not save time, > but I thought I'd send the idea out and see if anyone had already > tackled this problem.
This is how I usually feel too. Some systems have such complicated configs that it would be so much easier just to code the silly thing. I've always erred on the side of having more in the templates since it's customizable by so many more people than just the code. I agree that sometimes it's a pain when a change affects more than one template but if you have a good regression suite and you add tests before you add features then it's normally not a big deal. -- Michael Peters Developer Plus Three, LP --------------------------------------------------------------------- Web Archive: http://www.mail-archive.com/[email protected]/ http://marc.theaimsgroup.com/?l=cgiapp&r=1&w=2 To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
