1--TEST-- 2Check xsltprocessor::registerPHPFunctions and a non-string function in xsl 3--DESCRIPTION-- 4The XSL script tries to call a php function that is not a string which 5is expected to fail 6--EXTENSIONS-- 7xsl 8--FILE-- 9<?php 10include __DIR__ .'/prepare.inc'; 11$phpfuncxsl = new domDocument(); 12$phpfuncxsl->load(__DIR__."/phpfunc-nostring.xsl"); 13if(!$phpfuncxsl) { 14 echo "Error while parsing the xsl document\n"; 15 exit; 16} 17$proc->importStylesheet($phpfuncxsl); 18var_dump($proc->registerPHPFunctions()); 19var_dump($proc->transformToXml($dom)); 20?> 21--EXPECTF-- 22NULL 23 24Warning: XSLTProcessor::transformToXml(): Handler name must be a string in %s on line %d 25NULL 26--CREDITS-- 27Christian Weiske, cweiske@php.net 28PHP Testfest Berlin 2009-05-09 29