Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: xmlrpc_default_taxonomy_fields

To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).

Understanding Source Code

The best way to understand what a hook does is to look at where it occurs in the source code.

Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.

Source View

This hook occurs 2 times in this file.

Line Code
1908
1909           $blog_id        = (int) $args[0];
1910           $username       = $args[1];
1911           $password       = $args[2];
1912           $taxonomy       = $args[3];
1913
1914           if ( isset( $args[4] ) )
1915                $fields = $args[4];
1916           else
1917                $fields = apply_filters( 'xmlrpc_default_taxonomy_fields', array( 'labels', 'cap', 'object_type' ), 'wp.getTaxonomy' );
1918
1919           if ( ! $user = $this->login( $username, $password ) )
1920                return $this->error;
1921
1922           do_action( 'xmlrpc_call', 'wp.getTaxonomy' );
1923
1924           if ( ! taxonomy_exists( $taxonomy ) )
1925                return new IXR_Error( 403, __( 'Invalid taxonomy' ) );
1926
 
Line Code
1952
1953           $blog_id            = (int) $args[0];
1954           $username           = $args[1];
1955           $password           = $args[2];
1956           $filter             = isset( $args[3] ) ? $args[3] : array( 'public' => true );
1957
1958           if ( isset( $args[4] ) )
1959                $fields = $args[4];
1960           else
1961                $fields = apply_filters( 'xmlrpc_default_taxonomy_fields', array( 'labels', 'cap', 'object_type' ), 'wp.getTaxonomies' );
1962
1963           if ( ! $user = $this->login( $username, $password ) )
1964                return $this->error;
1965
1966           do_action( 'xmlrpc_call', 'wp.getTaxonomies' );
1967
1968           $taxonomies = get_taxonomies( $filter, 'objects' );
1969
1970           // holds all the taxonomy data