|
Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon. |
|
View previous topic :: View next topic |
Author |
Message |
msameerbutt Smarty Rookie
Joined: 02 Oct 2003 Posts: 11 Location: India
|
Posted: Tue Jul 27, 2004 10:57 am Post subject: How can i Store Template Output into PHP Variable instead of |
|
|
Hi There
How can i Store Template Output into PHP Variable Instead of displaying it
Please Help Me
Regards _________________ Hi I am New Comer
But Every one has this stage i will struggle hard need your help
thanks |
|
Back to top |
|
messju Administrator
Joined: 16 Apr 2003 Posts: 3336 Location: Oldenburg, Germany
|
Posted: Tue Jul 27, 2004 11:28 am Post subject: |
|
|
read the faq. it's in the wiki. |
|
Back to top |
|
msameerbutt Smarty Rookie
Joined: 02 Oct 2003 Posts: 11 Location: India
|
Posted: Wed Jul 28, 2004 5:27 am Post subject: |
|
|
Yes i Found that Problem in FAQ Section
------------------------------------------------------------------------------
Q: Is there anyway to send the compiled template code to a variable instead of $smarty->display() that output's it ? (I want to create a template for mail e.g)
A: use $smarty->fetch($name_of_template_file)-
------------------------------------------------------------------------------
But My problem is not solved Because the Above code Store Template out put in smarty Variable , but i want to store in a Php Variable. Actually i want to send that Template in mail as well as display. Can you Pls Tell me how can i do that hope you understand my problem
Regards _________________ Hi I am New Comer
But Every one has this stage i will struggle hard need your help
thanks |
|
Back to top |
|
boots Administrator
Joined: 16 Apr 2003 Posts: 5611 Location: Toronto, Canada
|
Posted: Wed Jul 28, 2004 6:06 am Post subject: |
|
|
[php:1:229a060222]<?php
$php_variable = $smarty->fetch($name_of_template_file);
?>[/php:1:229a060222] |
|
Back to top |
|
msameerbutt Smarty Rookie
Joined: 02 Oct 2003 Posts: 11 Location: India
|
Posted: Wed Jul 28, 2004 9:17 am Post subject: |
|
|
Thank you Very Much
Problem is Solved
Regards _________________ Hi I am New Comer
But Every one has this stage i will struggle hard need your help
thanks |
|
Back to top |
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|