Forums / Developer / 3.1 override weirdness

3.1 override weirdness

Author Message

Paul Forsyth

Friday 20 June 2003 9:03:45 am

Im having a problem with overrides. In the following override code I have three overrides, one for each view of a class. The overrides for full and menu views work as expected but line does not. When it display the line view defaults to that found in the standard node/view/line.tpl file, and not my override. I don't receive any errors. My permissions seem fine.

Does anyone else use line overrides in 3.1 (rev 2767)? Or am i doing something silly that i haven't spotted...

I should add that viewing the node/view/line.tpl file within the admin interface correctly shows my override.

[full_my_image]
Source=node/view/full.tpl
MatchFile=node/full_my_image.tpl
Subdir=templates
Match[class]=18

[line_my_image]
Source=node/view/line.tpl
MatchFile=node/line_my_image.tpl
Subdir=templates
Match[class]=18

[menu_my_image]
Source=node/view/menu.tpl
MatchFile=node/menu_my_image.tpl
Subdir=templates
Match[class]=18

And to display i use:

{node_view_gui view=line content_node=$my_node}

thanks

paul

Paul Forsyth

Friday 20 June 2003 9:26:13 am

Ah problem solved.

My actual code was:

{node_view_gui view=line content_node=$RO:item}

which was working of an related object array. but of course content_node requires a node, not a content object.

Entering:
{node_view_gui view=line content_node=$RO:item.main_node}

did the trick.

paul

eZ debug

Timing: Jan 18 2025 10:29:33
Script start
Timing: Jan 18 2025 10:29:33
Module start 'content'
Timing: Jan 18 2025 10:29:33
Module end 'content'
Timing: Jan 18 2025 10:29:33
Script end

Main resources:

Total runtime0.0200 sec
Peak memory usage2,048.0000 KB
Database Queries4

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0068 589.1172180.8438
Module start 'content' 0.00680.0060 769.960993.7266
Module end 'content' 0.01280.0071 863.687570.7031
Script end 0.0200  934.3906 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.002412.1358120.0002
Check MTime0.00136.2500120.0001
Mysql Total
Database connection0.00105.168110.0010
Mysqli_queries0.003617.912140.0009
Looping result0.00000.080920.0000
Template Total0.006733.610.0067
Template load0.00115.426310.0011
Template processing0.005628.191110.0056
Override
Cache load0.00083.993310.0008
General
dbfile0.00104.7669100.0001
String conversion0.00000.028630.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1pagelayout.tpl<No override>extension/sevenx/design/simple/templates/pagelayout.tplEdit templateOverride template
 Number of times templates used: 1
 Number of unique templates used: 1

Time used to render debug report: 0.0001 secs