XML block and passing on variables

Author Message

Lars Eirik R

Wednesday 11 November 2009 8:18:24 am

Hi.

I am having problems with figuring out how to pass variables to my ezxmltags/link.tpl.

I would like to be able to call attribute_view_gui attribute=bodytext url_type='full'

link.tpl should be able to get this variable and thus i am able to use aboslute url instead of relative url.

This does not work however.

Are there any ways of accomplishing such a thing without affecting the kernel or ezpublish classes ?

(The reason why this is needed, is so that my htmlemails will display links properly, not relative)

Romain Petit

Wednesday 11 November 2009 2:19:13 pm

Hi,

You can override the original link.tpl file and add "full" to the ezurl operator parameters.

Good luck.

Lars Eirik R

Wednesday 11 November 2009 2:23:58 pm

Thanks Romain.

I have managed to do so, but that forces me to output the links as absolute all the time.

My goal is toe be able to pass on a parameter which i can use to check for in my link.tpl

Is this possible? or am i not able to pass on a variable with attribute_view_gui for an xml block datatype ?

Lars Eirik R

Wednesday 11 November 2009 2:47:36 pm

I will just do what i have done already.. i will output all links in links.tpl as aboslute.

That way i make sure to stick to one scheme as well sa make sure that htmlemails contain correct and full urls.

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 30 2025 19:45:56
Script start
Timing: Jan 30 2025 19:45:56
Module start 'layout'
Timing: Jan 30 2025 19:45:56
Module start 'content'
Timing: Jan 30 2025 19:45:56
Module end 'content'
Timing: Jan 30 2025 19:45:56
Script end

Main resources:

Total runtime0.0252 sec
Peak memory usage6,144.0000 KB
Database Queries3

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0057 588.1406151.2109
Module start 'layout' 0.00570.0041 739.3516220.7031
Module start 'content' 0.00990.0135 960.0547997.7109
Module end 'content' 0.02330.0018 1,957.765633.9922
Script end 0.0251  1,991.7578 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.002811.2105140.0002
Check MTime0.00114.5323140.0001
Mysql Total
Database connection0.00083.259110.0008
Mysqli_queries0.002911.502130.0010
Looping result0.00000.071010.0000
Template Total0.00135.310.0013
Template load0.00093.764610.0009
Template processing0.00041.496610.0004
Override
Cache load0.00072.640010.0007
General
dbfile0.00031.207980.0000
String conversion0.00000.032240.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.0001 secs