Web студия "GrandView"
  Главная   Написать Контакты
   
   
О проекте
Руководство php
 

xslt_set_object

(PHP 4 >= 4.3.0, PECL)

xslt_set_object --  Sets the object in which to resolve callback functions

Description

bool xslt_set_object ( resource processor, object &obj )

This function allows to use the processor inside an object and to resolve all callback functions in it.

The callback functions can be declared with xml_set_sax_handlers(), xslt_set_scheme_handlers() or xslt_set_error_handler() and are assumed to be methods of object.

Примеры

Пример 1. Using your own error handler as a method

<?php

class my_xslt_processor {
   
    var
$_xh; // our XSLT processor
   
   
function my_xslt_processor()
    {
       
$this->_xh = xslt_create();

       
// Make $this object the callback resolver
       
xslt_set_object($this->_xh, $this);

       
// Let's handle the errors
       
xslt_set_error_handler($this->_xh, "my_xslt_error_handler");
    }

    function
my_xslt_error_handler($handler, $errno, $level, $info)
    {
       
// for now, let's just see the arguments
       
var_dump(func_get_args());
    }
}

?>


add a note add a note User Contributed Notes
xslt_set_object
There are no user contributed notes for this page.

xslt_set_sax_handler> <xslt_set_log
Last updated: Sat, 27 Jan 2007
 
 
Новости
11 июля 2007
Сайт запущен
© 2007 info@grandviewstudio.com

Deprecated: Function set_magic_quotes_runtime() is deprecated in /home/sites/grandviewstudiocom/www/65f67d67a94ad980786580ae69e11c07/sape.php on line 324

Deprecated: Function set_magic_quotes_runtime() is deprecated in /home/sites/grandviewstudiocom/www/65f67d67a94ad980786580ae69e11c07/sape.php on line 330
Z058440144362 Z348613067571