How to send the result of a template using ezMailTransport?

Author Message

Toni Ascó

Monday 14 June 2004 6:59:22 am

Hello, i have a module that theoretically should send an email. The content of the email should be the one that comes from a template, so i've done something like

$tpl->setVariable("message",$message);
result = $tpl->fetch("design:contact/templateMessage.tpl");
$mail->setBody($result);

and i send the mail,

I receive the mail correctly, but i don't get the message itself, the subjsect and such, is correct but there's nothing in the body...

Any idea?

Thx in advance,

Toni

ludo thomas

Wednesday 06 July 2005 8:49:04 am

I have exactly the same pb.
but some guys seem to make it works

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 19 2025 07:24:09
Script start
Timing: Jan 19 2025 07:24:09
Module start 'layout'
Timing: Jan 19 2025 07:24:09
Module start 'content'
Timing: Jan 19 2025 07:24:09
Module end 'content'
Timing: Jan 19 2025 07:24:09
Script end

Main resources:

Total runtime0.7379 sec
Peak memory usage4,096.0000 KB
Database Queries54

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0079 590.5469152.6563
Module start 'layout' 0.00790.0034 743.203139.5078
Module start 'content' 0.01130.7254 782.7109491.6250
Module end 'content' 0.73670.0012 1,274.33598.0938
Script end 0.7379  1,282.4297 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00370.5035160.0002
Check MTime0.00140.1963160.0001
Mysql Total
Database connection0.00120.161810.0012
Mysqli_queries0.689793.4579540.0128
Looping result0.00050.0720520.0000
Template Total0.702395.220.3511
Template load0.00280.374020.0014
Template processing0.699594.788120.3497
Template load and register function0.00010.018810.0001
states
state_id_array0.00180.239910.0018
state_identifier_array0.00090.126120.0005
Override
Cache load0.00230.3075160.0001
Sytem overhead
Fetch class attribute can translate value0.00080.115120.0004
Fetch class attribute name0.00130.181530.0004
XML
Image XML parsing0.00070.095020.0004
class_abstraction
Instantiating content class attribute0.00000.001130.0000
General
dbfile0.00210.2893160.0001
String conversion0.00000.001640.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
2content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
3content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
2content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 10
 Number of unique templates used: 6

Time used to render debug report: 0.0001 secs