Results of 1 - 4 of about 4 for xmldoc (0.001 sec.)
- XSLTProcessor::__construct — 新しい XSLTProcessor オブジェクトを作成する | PHP ... 12334
- XSLTProcessor::__construct (PHP 5, PHP 7, PHP 8) XSLTProcessor::__construct — 新しい XSLTProcessor オブジェクトを作成する 説明 function XSLTProcessor::__construct () 新しい XSLTProcessor オブジェクトを作成します。 パラメータ この関数にはパラ
... メータはありません。 例 例1 XSLTProcessor の作成 <?php $xsldoc = new DOMDocument (); $xsldoc -> load ( $xsl_filename ); $xmldoc = new DOMDocument (); $xmldoc -> load ( $xml_filename ); $xsl = new XSLTProcessor (); $xsl -> importStyleSheet ( $xsldoc ) ... ; echo $xsl -> transformToXML ( $xmldoc ); ?> ...
-
https://man.mtool.work/php/8.3/xsltprocessor.construct.html
- libxml のエラー処理関数によるエラー処理 | PHP 8.3 8968
- libxml のエラー処理関数によるエラー処理 libxml にはエラー処理用の関数が用意されており、これらを使うと、 XSLT の処理中のエラーを捕らえて対応できます。 例1 fruits.xml 妥当な XML ファイルです。 <fruits> <fruit>Apple</fruit> <fruit>Banana</frui
... むスタイルシートで XSLTProcessor::importStyleSheet() を呼んだ際に発生する libxml のエラーを捕らえて表示するものです。 <?php $xmldoc = new DOMDocument (); $xsldoc = new DOMDocument (); $xsl = new XSLTProcessor (); $xmldoc -> loadXML ( 'fruits.xml' ); $xsl ... ror: { $error -> message } \n" ; } } libxml_use_internal_errors ( false ); if ( $result ) { echo $xsl -> transformToXML ( $xmldoc ); } ?> 上の例の出力は、 たとえば以下のようになります。 Libxml error: Invalid expression Libxml error: compilation error: ...
-
https://man.mtool.work/php/8.3/xsl.examples-errors.html
- XSLTProcessor::registerPHPFunctionNS — PHP の関数を、名前空間付きの XSLT 関数と... 7933
- XSLTProcessor::registerPHPFunctionNS (PHP >= 8.4.0) XSLTProcessor::registerPHPFunctionNS — PHP の関数を、名前空間付きの XSLT 関数として登録する 説明 public function XSLTProcessor::registerPHPFunctionNS ( string $namespaceURI , string $name
... ="my:uppercase(string(uid))"/> </td> </tr> </xsl:for-each> </table> </body></html> </xsl:template> </xsl:stylesheet> EOB; $xmldoc = new DOMDocument (); $xmldoc -> loadXML ( $xml ); $xsldoc = new DOMDocument (); $xsldoc -> loadXML ( $xsl ); $proc = new ... , 'count' , fn (array $arg1 ) => count ( $arg1 )); $proc -> importStyleSheet ( $xsldoc ); echo $proc -> transformToXML ( $xmldoc ); ?> 参考 DOMXPath::registerPhpFunctionNS() - PHP の関数を、名前空間付きの XPath 関数として登録する DOMXPath::registerPhp ...
-
https://man.mtool.work/php/8.3/xsltprocessor.registerphpfunctionns.html
- XSLTProcessor::registerPHPFunctions — PHP 関数を XSLT 関数として利用できるよう... 7711
- XSLTProcessor::registerPHPFunctions (PHP 5 >= 5.0.4, PHP 7, PHP 8) XSLTProcessor::registerPHPFunctions — PHP 関数を XSLT 関数として利用できるようにする 説明 public function XSLTProcessor::registerPHPFunctions ( array | string | null $functi
... ction('ucfirst',string(uid))"/> </td></tr> </xsl:for-each> </table> </body></html> </xsl:template> </xsl:stylesheet> EOB; $xmldoc = new DOMDocument (); $xmldoc -> loadXML ( $xml ); $xsldoc = new DOMDocument (); $xsldoc -> loadXML ( $xsl ); $proc = new ... XSLTProcessor (); $proc -> registerPHPFunctions (); $proc -> importStyleSheet ( $xsldoc ); echo $proc -> transformToXML ( $xmldoc ); ?> 参考 DOMXPath::registerPhpFunctions() - PHP の関数を XPath 関数として登録する 他のマニュアルの関連ページ Linux JM pr ...
-
https://man.mtool.work/php/8.3/xsltprocessor.registerphpfunctions.html
PREV
1
NEXT