Thorsten Scherler a écrit :

On Wed, 2005-07-27 at 19:47 +0200, Thorsten Scherler wrote:
On Wed, 2005-07-27 at 18:17 +0200, Cyriaque Dupoirieux wrote:
Just a remark,

When you use twice the same contract in a page, the *.js are include twice in the header.
Only the includes call or the whole head template?


The whole head template. it is fixed now.

   ( It also works with *.css includes :-) )

You mean if you use:
<forrest:css url="default.css"/>
<forrest:css url="default.css"/>

Hmm, we can prevent that, but do we have to and want to?

I enabled this now as well even if IMO we should find a better way to
prevent this issue from happening. One should not be able to include a
forrest:css with the same @url in a view.
I was not talking about <forrest:css url="anyfile.css"/> included several times in an *.fv - IMO this is the writer responsibility to be carreful of what he includes in his view.
(We cannot control that the included css is necessary...)

I was talking about the myContract-head content.

In fact, I was trying to dispatch the content of a whole css used with pelt 
skin - screen.css - into several specific css included by the different 
contracts.
Benefits of this is that css :

   * are smaller and easy to understand
   * contains only what the contract needs
   * are only included if necessary, that is if you use the contract in
     your view.

Disadvantages are :

   * the number of included files in the HTML page increase. (but I
     don't know if it can have an impact on performance.)

Thank you for your correction, I will try this today.

Salutations,
Cyriaque,


svn log:
fixed the multiple include of head templates calls and as well the css
include. Now even if we use twice a contract that is requesting
{contract-name}-head it just get called once. The same is true for
forrest:css. If you use two times the same @url it still only get
includes once.

Cheers for the report.

salu2


I will have a look tonight.

salu2

Reply via email to