当前位置: 首页>>代码示例>>PHP>>正文


PHP Redux::setExtensions方法代码示例

本文整理汇总了PHP中Redux::setExtensions方法的典型用法代码示例。如果您正苦于以下问题:PHP Redux::setExtensions方法的具体用法?PHP Redux::setExtensions怎么用?PHP Redux::setExtensions使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Redux的用法示例。


在下文中一共展示了Redux::setExtensions方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: dirname

<?php

if (class_exists('Redux')) {
    $opt_name = 'pinnacle';
    Redux::setExtensions($opt_name, dirname(__FILE__) . '/extensions/');
}
开发者ID:oeuvrayjoris,项目名称:grece,代码行数:6,代码来源:pinnacle_extension.php

示例2: getInstanceExtensions

 public static function getInstanceExtensions($opt_name, $instance = array())
 {
     if (!empty(self::$uses_extensions[$opt_name])) {
         return;
     }
     if (empty($instance)) {
         $instance = ReduxFrameworkInstances::get_instance($opt_name);
     }
     if (empty($instance) || empty($instance->extensions)) {
         return;
     }
     foreach ($instance->extensions as $name => $extension) {
         if ($name == "widget_areas") {
             $new = new Redux_Widget_Areas($instance);
         }
         if (isset(self::$uses_extensions[$opt_name][$name])) {
             continue;
         }
         if (isset($extension->extension_dir)) {
             Redux::setExtensions($opt_name, str_replace($name, '', $extension->extension_dir));
         } else {
             if (isset($extension->_extension_dir)) {
                 Redux::setExtensions($opt_name, str_replace($name, '', $extension->_extension_dir));
             }
         }
     }
 }
开发者ID:jesusmarket,项目名称:jesusmarket,代码行数:27,代码来源:class.redux_api.php

示例3: dirname

<?php

// All extensions placed within the extensions directory will be auto-loaded for your Redux instance.
Redux::setExtensions('redux_builder_burocrate', dirname(__FILE__) . '/extensions/');
// Any custom extension configs should be placed within the configs folder.
if (file_exists(dirname(__FILE__) . '/configs/')) {
    $files = glob(dirname(__FILE__) . '/configs/*.php');
    if (!empty($files)) {
        foreach ($files as $file) {
            include $file;
        }
    }
}
开发者ID:rusakoff,项目名称:tonic-first,代码行数:13,代码来源:extensions-init.php

示例4: register_activation_hook

register_activation_hook(__FILE__, 'add_roles_on_plugin_activation');
function vbs_load_plugin_textdomain()
{
    load_plugin_textdomain('vbs', FALSE, basename(dirname(__FILE__)) . '/languages/');
}
add_action('plugins_loaded', 'vbs_load_plugin_textdomain');
if (isset($_REQUEST['action']) && $_REQUEST['action'] == 'ajaxFunctionMethod') {
    do_action('wp_ajax_' . $_REQUEST['action']);
    do_action('wp_ajax_nopriv_' . $_REQUEST['action']);
}
// Include the Redux files
if (!class_exists('ReduxFramework') && file_exists(dirname(__FILE__) . '/admin/framework.php')) {
    require_once PLUGIN_DIR . 'admin/framework.php';
}
require_once dirname(__FILE__) . '/admin/admin-config.php';
Redux::setExtensions('booking', dirname(__FILE__) . '/admin/vendor_support');
if (!class_exists('RW_Meta_Box')) {
    require_once 'include/meta-box/meta-box.php';
}
include 'include/custom-post-types.php';
include 'include/meta-boxes.php';
include 'include/shortcodes.php';
include 'include/calculator.php';
include 'include/form_handler.php';
include 'include/helper.php';
include 'include/email.php';
// TGM activation class
require_once PLUGIN_DIR . 'include/tgm/tgm-init.php';
add_action('admin_enqueue_scripts', 'add_admin_scripts', 10, 1);
function add_admin_scripts($hook)
{
开发者ID:arsen77,项目名称:vehicle-booking-system,代码行数:31,代码来源:vbs.php


注:本文中的Redux::setExtensions方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。