Smarty Forum Index Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon.

Search found 22 matches
Smarty Forum Index
Author Message
  Topic: Slight problem with delimeters and whitespaces
kk

Replies: 1
Views: 8920

PostForum: Smarty 3   Posted: Tue Aug 27, 2013 7:59 am   Subject: Slight problem with delimeters and whitespaces
It might be just me but I experience a problem that smarty doesn't accept line breaks as whitespaces anymore.

<script type="text/javascript">

$(function() { ...
  Topic: Syntax for include
kk

Replies: 4
Views: 17610

PostForum: Smarty 3   Posted: Fri Jun 28, 2013 4:22 pm   Subject: Syntax for include
Short form it is.

attribute name 'file' should change to 'resource' to avoid people like me getting confused.

Thanks for quick reply.
  Topic: Syntax for include
kk

Replies: 4
Views: 17610

PostForum: Smarty 3   Posted: Fri Jun 28, 2013 9:10 am   Subject: Syntax for include
Sorry if this was mentioned earlier or explained why this should be like that but maybe just an idea to improve 'readability' of the include tag.
Wouldn't it be nicer to exclude the resource type fro ...
  Topic: Include with own custom template resource doesn’t get assign
kk

Replies: 8
Views: 14819

PostForum: Smarty 3   Posted: Tue Feb 07, 2012 11:46 pm   Subject: Include with own custom template resource doesn’t get assign
Of course I have compiled code after the event.
Before that no cached or compiled code was on the system.
  Topic: Include with own custom template resource doesn’t get assign
kk

Replies: 8
Views: 14819

PostForum: Smarty 3   Posted: Tue Feb 07, 2012 9:46 pm   Subject: Include with own custom template resource doesn’t get assign
not before the code is running...
  Topic: Include with own custom template resource doesn’t get assign
kk

Replies: 8
Views: 14819

PostForum: Smarty 3   Posted: Tue Feb 07, 2012 9:33 pm   Subject: Include with own custom template resource doesn’t get assign
No cached or compiled version on the system.
First try with given code produces this problem.
  Topic: Include with own custom template resource doesn’t get assign
kk

Replies: 8
Views: 14819

PostForum: Smarty 3   Posted: Tue Feb 07, 2012 7:45 pm   Subject: Include with own custom template resource doesn’t get assign
like this:

<?php
class Smarty_Resource_Module extends Smarty_Resource_Custom {
/**
* Fetch a template and its modification time from database
*
* @param string $name template name ...
  Topic: Include with own custom template resource doesn’t get assign
kk

Replies: 8
Views: 14819

PostForum: Smarty 3   Posted: Tue Feb 07, 2012 7:19 pm   Subject: Include with own custom template resource doesn’t get assign
It seems that I can’t populate simple smarty variables like {$value} in a included template using my own custom template resource. I see the content but not anything which should be propagated automat ...
  Topic: compile and cache confusion.
kk

Replies: 9
Views: 17136

PostForum: Smarty 3   Posted: Fri Sep 30, 2011 5:58 pm   Subject: compile and cache confusion.
That makes sense. Indeed I used echo to get the values displayed.

One more:
What purpose does the 3rd parameter of the method fetch() have? Does this need to be filled with a real timestamp value? ...
  Topic: compile and cache confusion.
kk

Replies: 9
Views: 17136

PostForum: Smarty 3   Posted: Fri Sep 30, 2011 7:07 am   Subject: compile and cache confusion.
I solved the timestamp problem. Thanks for the help on that.
And thanks for explaining the cache - compile relationship.

But, the double call still happens.

Situation: Clear all cached files an ...
  Topic: compile and cache confusion.
kk

Replies: 9
Views: 17136

PostForum: Smarty 3   Posted: Thu Sep 29, 2011 8:45 pm   Subject: compile and cache confusion.
Thanks for quick reply.

1. Yes it was a typo.
2. That’s make sense
3. In my case cacheDir contains only the ‘root’ template and none of the additional modules which are requested by {include file ...
  Topic: compile and cache confusion.
kk

Replies: 9
Views: 17136

PostForum: Smarty 3   Posted: Thu Sep 29, 2011 7:08 pm   Subject: compile and cache confusion.
I might be slow in the intake but I try to understand the compiling – caching behaviour.

When should Smarty compile the templates? Every time or after a certain amount of time?
When would I use ca ...
  Topic: problem with {include nocache}
kk

Replies: 2
Views: 6743

PostForum: Smarty 3   Posted: Mon Sep 26, 2011 9:56 pm   Subject: problem with {include nocache}
I thought that the nocache entry would force a compile without using a timestamp check.
How would I find out that nocache was set in {include}?
  Topic: problem with {include nocache}
kk

Replies: 2
Views: 6743

PostForum: Smarty 3   Posted: Mon Sep 26, 2011 8:09 pm   Subject: problem with {include nocache}
{include file="module:testTemplate" nocache}

Using my own resource 'module' to retrieve templates generated from a file, database entry or php code the usage of nocache doesn’t affect the ...
  Topic: get error message but why?
kk

Replies: 2
Views: 5012

PostForum: Smarty 3   Posted: Thu Nov 25, 2010 10:00 pm   Subject: get error message but why?
Silly me. I thought I did.
Thanks
 
Page 1 of 2 Goto page 1, 2  Next
All times are GMT
Jump to:  


Powered by phpBB © 2001, 2005 phpBB Group
Protected by Anti-Spam ACP