IT. Expert System.

PHP

Sets the object in which to resolve callback functions


xslt_set_object

(PHP 4 >= 4.3.0)

xslt_set_objectSets 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 xslt_set_sax_handlers(), xslt_set_scheme_handlers() or xslt_set_error_handler() and are assumed to be methods of object.

Parameters

processor

The XSLT processor link identifier, created with xslt_create().

obj

An object.

Return Values

Returns TRUE on success or FALSE on failure.

Examples

Example #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());
    }
}

?>


Content

Android Reference

Java basics

Java Enterprise Edition (EE)

Java Standard Edition (SE)

SQL

HTML

PHP

CSS

Java Script

MYSQL

JQUERY

VBS

REGEX

C

C++

C#

Design patterns

RFC (standard status)

RFC (proposed standard status)

RFC (draft standard status)

RFC (informational status)

RFC (experimental status)

RFC (best current practice status)

RFC (historic status)

RFC (unknown status)

IT dictionary

License.
All information of this service is derived from the free sources and is provided solely in the form of quotations. This service provides information and interfaces solely for the familiarization (not ownership) and under the "as is" condition.
Copyright 2016 © ELTASK.COM. All rights reserved.
Site is optimized for mobile devices.
Downloads: 116 / 158781155. Delta: 0.03711 с