Forum OpenACS Q&A: Re: ajaxhelper and its tests

Posted by Antonio Pisano on
We already have two separate procs to include js in head or in body, and for a good reason I think, as they must be put in different places on the page.

Javascript in head should never be replicated, as it is meant to be loaded and/or executed just once, while body could have multiple inclusions (js that should fire the same for each row in a table is an example)

I don't think there is need for merging the two procs in a more generical one. Some little code replication exists, but removing that could be as good as letting thing as they are, leaving space for further difference in script management.