PHP Класс WPDKTheme

Автор: =undo= ([email protected])
Наследование: extends WPDKObject
Показать файл Открыть проект

Открытые свойства

Свойство Тип Описание
$__version string Override version
$assetsURL string The Theme URL more assets/. This property is very useful for read style sheet and Javascript file in the 'assets' folder.
$classPath string The Filesystem theme path more classes/
$cssURL string The Theme URL more assets/css/
$imagesURL string The Theme URL more assets/css/images/
$javascriptURL string The Theme URL more assets/js/
$path string Filesystem theme path. Alias TEMPLATEPATH
$setup WPDKThemeSetup Theme Setup class model
$theme WP_Theme Instance of WP_Theme class

Открытые методы

Метод Описание
__construct ( string $file, boolean | WPDKThemeSetup $setup = false ) : WPDKTheme Create an instance of WPDKTheme class
_after_setup_theme ( ) Internal use
_body_classes ( $classes ) Add a your custom class in body tag class attribute and make the array (classes attribute) unique.
_init ( ) Do a several Clean Up
_wp_head ( ) Print scripts or data in the head tag on the front end.
admin_init ( ) This action is used to avoid display the admin backend area to subscriber user
after_setup_theme ( ) Setup theme
ajax ( ) Subclass for init Ajax gateway
autoloadEnvironment ( string $sClassName ) This function performs runtime autoloading of a class specifically related to this instance; this autoloading is based on previous class registering that has to be executed before.
image_size_names_choose ( array $sizes ) : array Allows modification of the list of image sizes that are available to administrators in the WordPress Media Library.
init_shortcode ( ) Subclass for inti your shortcode.
init_theme ( ) Init the theme
registerAutoloadClass ( string | array $sLoadingPath, string $mClassName = '' ) This function records a WPX theme class into autoloading register, joined with its loading path.
wp_enqueue_scripts ( ) Fires when scripts and styles are enqueued.
wp_footer ( ) Subclass to insert output in the fotter
wp_head ( ) Print scripts or data in the head tag on the front end.
wp_print_styles ( ) Fires before styles in the $handles queue are printed.

Описание методов

__construct() публичный Метод

Create an instance of WPDKTheme class
public __construct ( string $file, boolean | WPDKThemeSetup $setup = false ) : WPDKTheme
$file string
$setup boolean | WPDKThemeSetup Optional. A your custom theme setup class model
Результат WPDKTheme

_after_setup_theme() публичный Метод

Internal use
public _after_setup_theme ( )

_body_classes() публичный Метод

Add a your custom class in body tag class attribute and make the array (classes attribute) unique.
public _body_classes ( $classes )

_init() публичный Метод

Do a several Clean Up
public _init ( )

_wp_head() публичный Метод

Print scripts or data in the head tag on the front end.
public _wp_head ( )

admin_init() публичный Метод

This action is used to avoid display the admin backend area to subscriber user
public admin_init ( )

after_setup_theme() публичный Метод

Setup theme
public after_setup_theme ( )

ajax() публичный Метод

Subclass for init Ajax gateway
public ajax ( )

autoloadEnvironment() публичный Метод

NOTE: this SPL autoloading logic is encapsulated in every single plugin instance that extends this class, because it is embedded into an instance of WPDKWordPressPlugin. So any plugin has its own SPL autoloading logic.
public autoloadEnvironment ( string $sClassName )
$sClassName string - The class that has to be loaded right now

image_size_names_choose() публичный Метод

Allows modification of the list of image sizes that are available to administrators in the WordPress Media Library.
public image_size_names_choose ( array $sizes ) : array
$sizes array Sizes list
Результат array

init_shortcode() публичный Метод

Subclass for inti your shortcode.
public init_shortcode ( )

init_theme() публичный Метод

Init the theme
public init_theme ( )

registerAutoloadClass() публичный Метод

The function has some facility in its first param, in order to allow both string and array loading of class names ( useful in case of a group of classes that are defined in a single file ). 1. $this->registerAutoloadClass( 'file.php', 'ClassName' ); 2. $this->registerAutoloadClass( array( 'file.php' => 'ClassName' ) ); 3. $this->registerAutoloadClass( array( 'file.php' => array( 'ClassName', 'ClassName', ... ) ) );
public registerAutoloadClass ( string | array $sLoadingPath, string $mClassName = '' )
$sLoadingPath string | array Path of class when $mClassName is a string
$mClassName string Optional. The single class name or key value pairs array with path => classes

wp_enqueue_scripts() публичный Метод

Fires when scripts and styles are enqueued.
public wp_enqueue_scripts ( )

wp_head() публичный Метод

Print scripts or data in the head tag on the front end.
public wp_head ( )

wp_print_styles() публичный Метод

Fires before styles in the $handles queue are printed.
public wp_print_styles ( )

Описание свойств

$__version публичное свойство

Override version
public string $__version
Результат string

$assetsURL публичное свойство

The Theme URL more assets/. This property is very useful for read style sheet and Javascript file in the 'assets' folder.
public string $assetsURL
Результат string

$classPath публичное свойство

The Filesystem theme path more classes/
public string $classPath
Результат string

$cssURL публичное свойство

The Theme URL more assets/css/
public string $cssURL
Результат string

$imagesURL публичное свойство

The Theme URL more assets/css/images/
public string $imagesURL
Результат string

$javascriptURL публичное свойство

The Theme URL more assets/js/
public string $javascriptURL
Результат string

$path публичное свойство

Filesystem theme path. Alias TEMPLATEPATH
public string $path
Результат string

$setup публичное свойство

Theme Setup class model
public WPDKThemeSetup $setup
Результат WPDKThemeSetup

$theme публичное свойство

Instance of WP_Theme class
public WP_Theme $theme
Результат WP_Theme