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 13 matches
Smarty Forum Index
Author Message
  Topic: Summa elementov massiva
SiZE

Replies: 4
Views: 16934

PostForum: Language: Russian   Posted: Mon Jan 24, 2011 7:32 am   Subject: Summa elementov massiva
{assign var="array_sum" value=$array|@array_sum}
  Topic: Smarty 3: variable variables
SiZE

Replies: 10
Views: 84292

PostForum: Tips and Tricks   Posted: Mon Jan 24, 2011 7:25 am   Subject: Smarty 3: variable variables
I don't understund. Is it similar to php's

$var = 'hello';

$$var = 'world'

echo $hello; // print world

?

Cause I search working set for Smarty 2 and make something like this in my templ ...
  Topic: Kak obrabotat funktsii v parametre
SiZE

Replies: 3
Views: 13717

PostForum: Language: Russian   Posted: Thu Sep 23, 2010 11:22 am   Subject: Kak obrabotat funktsii v parametre
может попробовать обернуть стро& ...
  Topic: Indeksy associativnogo massiva
SiZE

Replies: 1
Views: 10234

PostForum: Language: Russian   Posted: Thu Sep 23, 2010 5:27 am   Subject: Indeksy associativnogo massiva
{assign var='lang' value="title_`$config.lang`"}
{$arr.$lang}
  Topic: Podskajite kak ustanovit' default value dlya array
SiZE

Replies: 2
Views: 12032

PostForum: Language: Russian   Posted: Thu Sep 23, 2010 5:01 am   Subject: Podskajite kak ustanovit' default value dlya array
fixed in svn
  Topic: Couldn't set default value for array
SiZE

Replies: 5
Views: 10728

PostForum: Smarty 3   Posted: Thu Sep 23, 2010 4:53 am   Subject: Couldn't set default value for array
thanks
  Topic: Couldn't set default value for array
SiZE

Replies: 5
Views: 10728

PostForum: Smarty 3   Posted: Wed Sep 22, 2010 8:53 am   Subject: Couldn't set default value for array
It's a varchar field from db table. So, if I set some non-existent variable, like, {$test}, {$test.test}, ${test|default:'ok'}, ${test.test|default:'ok'} - smarty template compilator has no errors. Bu ...
  Topic: Podskajite kak ustanovit' default value dlya array
SiZE

Replies: 2
Views: 12032

PostForum: Language: Russian   Posted: Tue Sep 21, 2010 7:12 am   Subject: Podskajite kak ustanovit' default value dlya array
{$request.name|default:''} - vizivaet PHP oshibku esli net index 'name'.

Viyasnil 4to dlya peremennoi rabotaet, a dlya massiva net.
  Topic: Couldn't set default value for array
SiZE

Replies: 5
Views: 10728

PostForum: Smarty 3   Posted: Tue Sep 21, 2010 7:08 am   Subject: Couldn't set default value for array
When error, smarty_modifier_default has param $string = NULL;

P.S. May be I could set default values for all smarty properties ?
  Topic: Couldn't set default value for array
SiZE

Replies: 5
Views: 10728

PostForum: Smarty 3   Posted: Tue Sep 21, 2010 7:03 am   Subject: Couldn't set default value for array
{$request|default:'-'} - all ok

{$request.name|default:'-'} - PHP error notice

Is it bug or feature? Smile
  Topic: Troubles with assignByRef
SiZE

Replies: 2
Views: 5872

PostForum: Smarty 3   Posted: Wed Sep 15, 2010 5:47 pm   Subject: Troubles with assignByRef
Hm.. I solved a problem. I declare in construct another container method throw link, like in IPB ipsregistry. If I remove it or if i set it to private all is ok. Otherwise it's go to the endless circl ...
  Topic: Troubles with assignByRef
SiZE

Replies: 2
Views: 5872

PostForum: Smarty 3   Posted: Wed Sep 15, 2010 5:23 pm   Subject: Troubles with assignByRef
UPD:
Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 289259 bytes) in D:\home\work\admin\includes\smarty\plugins\modifier.debug_print_var.php on line ...
  Topic: Troubles with assignByRef
SiZE

Replies: 2
Views: 5872

PostForum: Smarty 3   Posted: Wed Sep 15, 2010 5:07 pm   Subject: Troubles with assignByRef
Hello! I'm having a simple class with methods. I declare it, something like this:

$test = new test();
$_smarty->assignByRef( 'test', $test );

So, I added to my 'test' class a ...
 
Page 1 of 1
All times are GMT
Jump to:  


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