芝麻web文件管理V1.00
编辑当前文件:/home2/sdektunc/timucuy.com/wp-content/themes/hestia/inc/core/class-hestia-feature-factory.php
*/ class Hestia_Feature_Factory { /** * The build method for creating a new Hestia class. * * @since 1.0.0 * @access public * @param string $feature_name The name of the feature to instantiate. * @return mixed */ public static function build( $feature_name ) { $feature_words = explode( '-', $feature_name ); $feature_words = array_map( 'ucfirst', $feature_words ); $feature_name = implode( '_', $feature_words ); $class = 'Hestia_' . $feature_name; if ( class_exists( $class ) ) { return new $class; } return null; } }