Find the Exponential Software extensions you want
UNIX name | Owner | Status |
---|---|---|
wrap_operator | Brookins Consulting | stable |
Version | Compatible with |
---|---|
1.0.1 | 4.0+ |
Essentially, this is a simple wrapper operator to directly call any system and user-defined functions in template.
It does not concern me much if doing so is good idea or ' pfui' as someone said once on the #ezpublish irc channel.
Undoubtedly care has to be taken to avoid security and caching problems, etc.
But it makes life a lot easier for me because I don't have to re-implement / write existing text processing functions in template language and do not need to set up separate extension to every small operator I need.
It's a swiss army knife - you can cut your hand but no one is forcing you to :)
I am not sure exactly what datatypes can be passed to functions from template like this.
Should work ok for integers, strings and boolean I think. If you are more informed about ez internals, please comment.
Using wrap_user_func with return_output=true() should enable easy embedding of existing php applications in templates, called through the user function. I have tested just simple test case but maybe someone can think of something more useful and post specific instructions..