Documentation for creating custom template functions

Author Message

Eirik Alfstad Johansen

Saturday 26 February 2005 4:40:56 am

Hi,

I was just wondering if there exists any documentation on creating custom template functions (not operators), alternatively, if anyone know of an extension containing a custom template function that I can examine.

Thanks in advance !

Sincerely,

Eirik Alfstad Johansen
http://www.netmaking.no/

Gabriel Ambuehl

Saturday 26 February 2005 5:17:20 am

What are you trying to do? Personally, I couldn't really find a clear difference between operator and function...

Visit http://triligon.org

Eirik Alfstad Johansen

Saturday 26 February 2005 5:32:36 am

Hi Gabriel,

To be honest, I'm not sure about the difference between operators and functions myself, but what I need to do is create something very similar to the shop_account_view_gui function, and since that is a function, I figured that that's what I need. :)

Sincerely,

Eirik Alfstad Johansen
http://www.netmaking.no/

Gabriel Ambuehl

Saturday 26 February 2005 6:22:48 am

I never looked into the view stuff. But I thought I once came across a description of how to create your own views?

Visit http://triligon.org

Paul Forsyth

Tuesday 01 March 2005 1:02:48 pm

Hi Eirik,

I havent used those operators before but i've just noticed a good example:

http://zev.ez.no/svn/extensions/survey/trunk/

Look in the autoload directory

paul

Eirik Alfstad Johansen

Wednesday 02 March 2005 7:32:55 am

Thanks a lot, Paul. Due to time constraints, I worked around the problem using an operator, but I will definetly look into this code the next time I encounter a similar problem.

Sincerely,

Eirik Alfstad Johansen
http://www.netmaking.no/

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 20 2025 03:09:46
Script start
Timing: Jan 20 2025 03:09:46
Module start 'layout'
Timing: Jan 20 2025 03:09:46
Module start 'content'
Timing: Jan 20 2025 03:09:46
Module end 'content'
Timing: Jan 20 2025 03:09:46
Script end

Main resources:

Total runtime0.0235 sec
Peak memory usage2,048.0000 KB
Database Queries3

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0059 589.3047152.6406
Module start 'layout' 0.00590.0032 741.945339.4766
Module start 'content' 0.00910.0108 781.421993.2734
Module end 'content' 0.01990.0035 874.695338.3047
Script end 0.0234  913.0000 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.003012.7029140.0002
Check MTime0.00135.5649140.0001
Mysql Total
Database connection0.00093.767210.0009
Mysqli_queries0.002510.727330.0008
Looping result0.00000.076210.0000
Template Total0.002410.210.0024
Template load0.00156.350410.0015
Template processing0.00093.772210.0009
Override
Cache load0.00093.891110.0009
General
dbfile0.00114.637180.0001
String conversion0.00000.043740.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

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

Time used to render debug report: 0.0002 secs