I have a zclass (with ZObject, ZObjectManager baseclasses) "Content" with a method index_html. If it is possible, how may i add an index_html to the instances of "content"?: /zclass Content | index_html Content instance | index_html Best regards Eianr Næss Jensen -- Einar Næss Jensen Avdelingsingeniør IT-HF 735 90750
Einar Næss Jensen wrote:
I have a zclass (with ZObject, ZObjectManager baseclasses) "Content" with a method index_html. If it is possible, how may i add an index_html to the instances of "content"?:
/zclass Content | index_html
Content instance | index_html
Probably easiest is to make a conditional /zclass Content | index_html would contain something like <dtml-if custom_index_html> <dtml-var custom_index_html> <dtml-else> [standard content] </dtml-if> and Content instance | custom_index_html contains the instance-specific content --Jim Washington
Jim Washington wrote:
Einar Næss Jensen wrote:
I have a zclass (with ZObject, ZObjectManager baseclasses) "Content" with a method index_html. If it is possible, how may i add an index_html to the instances of "content"?:
/zclass Content | index_html
Content instance | index_html
Probably easiest is to make a conditional
/zclass Content | index_html
would contain something like
<dtml-if custom_index_html> <dtml-var custom_index_html> <dtml-else> [standard content] </dtml-if>
and
Content instance | custom_index_html
contains the instance-specific content
Yes. But that's not what I want I ended up with this, more or less stupid, workaround, which suits my needs In my zclass i have DEFAULT_index_html In my instance I have index.html AND: somewhere at the root I have an index_html which load index.html (and different variants) OR DEFAULT_index_html This may seem stupid, but works for me.
participants (3)
-
Einar Næss Jensen -
Einar Næss Jensen -
Jim Washington