|
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 |
Bon/V Smarty Rookie
Joined: 25 Feb 2011 Posts: 7
|
Posted: Fri Feb 25, 2011 2:14 pm Post subject: Is changed $tag_arg format for Compiler plugin? |
|
|
About $tag_arg format for Compiler plugin.
Is it changed a spec?
eg.
{myplugin arg1 arg2}
function smarty_compiler_myplugin($tag_arg, &$o_Smarty) {
// $tag_arg:
// Till 2.6.26: get "arg1 arg2"
// Till 3.0.6 : get array(arg1, arg2}
// Now 3.0.7: cannot get...
}
If {myplugin a=arg1 b=arg2},
I can get array('a'=>'arg1', 'b'=>'arg2'). |
|
Back to top |
|
U.Tews Administrator
Joined: 22 Nov 2006 Posts: 5068 Location: Hamburg / Germany
|
Posted: Fri Feb 25, 2011 4:24 pm Post subject: |
|
|
This was a bug which is now fixed in the SVN trunk version.
If you pass unnamed attributs like in your {myplugin arg1 arg2} example you will now get array(arg1, arg2) as in the earlier Smarty3 releases. |
|
Back to top |
|
Bon/V Smarty Rookie
Joined: 25 Feb 2011 Posts: 7
|
Posted: Fri Feb 25, 2011 11:51 pm Post subject: |
|
|
Thank you for your immediate reply!
It worked on SVN Rev.4023.
I will check SVN earlier from now on. |
|
Back to top |
|
Bon/V Smarty Rookie
Joined: 25 Feb 2011 Posts: 7
|
Posted: Sun Sep 18, 2011 12:58 pm Post subject: |
|
|
This issue recurred.
{myplugin arg1 arg2}
function smarty_compiler_myplugin($tag_arg, &$o_Smarty) {
// $tag_arg:
// 3.0.8 : get array(arg1, arg2}
// 3.1.0: cannot get...
}
At 3.1.0:
If {myplugin a=arg1 b=arg2},
I can get array('a'=>'arg1', 'b'=>'arg2'). |
|
Back to top |
|
U.Tews Administrator
Joined: 22 Nov 2006 Posts: 5068 Location: Hamburg / Germany
|
Posted: Sun Sep 18, 2011 6:38 pm Post subject: |
|
|
For some reasion this change was not included in 3.1.
It's now in the SVN trunk |
|
Back to top |
|
Bon/V Smarty Rookie
Joined: 25 Feb 2011 Posts: 7
|
Posted: Mon Sep 19, 2011 12:56 am Post subject: |
|
|
Thank you for your immediate reply!
It worked on SVN Rev.4288. |
|
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
|