| Friday 15 December 2006 7:35:00 am 
                                                                 Alternately you can use a php template operator as the above php function uses just one parameter (limitation). 
PHP Function: '<i>file_get_contents</i>'<i>http://us2.php.net/file_get_contents</i>
 Add this line to your setting file, '<i>settings/siteaccess/example/template.ini.append.php</i>'. 
[PHP]
PHPOperatorList[file_get_contents]=file_get_contents
  Add this line to your pagelayout file, '<i>design/example/templates/pagelayout.tpl</i>'. 
{'http://yahoo.com/'|file_get_contents()}
 Alternately, if you need to use a php function using many arguments, you will want to use the 'wrap_operator' extension (in contributions). <i>http://ez.no/community/contribs/template_plugins/wrapper_operator</i> Add this line to your setting file, '<i>settings/override/wrap_operator.ini.append.php</i>'. 
[PHPFunctions]
PermittedFunctionList[]
PermittedFunctionList[]=file_get_contents
  Add this line to your pagelayout file, '<i>design/example/templates/pagelayout.tpl</i>'. 
{wrap_php_func('file_get_contents', 'http://google.com/' )}
 Well still you could pass additional arguments as well using this method. 
{wrap_php_func('file_get_contents', array( 'http://google.com/', FALSE, NULL, 0, 0 ) )}
 And and after that you can write as many user defined functions in php and use them as php or template operators with the wrap_operator extension. A very flexible tool to provide for simple solutions. Still ... beware of cache and cache block (possible) related considerations. 
//kracker<i>tv: metalocalypse</i>
 Member since: 2001.07.13 || http://ezpedia.se7enx.com/
                                                                 |