• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP RevSlider类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

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



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

示例1: import_revslider

 function import_revslider($other_data)
 {
     $is_import = false;
     if ($handle = opendir(THEME_DIR . "assets" . DIRECTORY_SEPARATOR . "data-demo" . DIRECTORY_SEPARATOR . "revslider")) {
         $arr_other_data = explode('||', $other_data);
         while (false !== ($entry = readdir($handle))) {
             if (in_array($entry, $arr_other_data)) {
                 continue;
             }
             if ($entry != "." && $entry != "..") {
                 $rev_import_file = THEME_DIR . "assets" . DIRECTORY_SEPARATOR . "data-demo" . DIRECTORY_SEPARATOR . "revslider" . DIRECTORY_SEPARATOR . $entry;
                 if (class_exists('RevSlider')) {
                     $slider = new RevSlider();
                     $response = $slider->importSliderFromPost(true, true, $rev_import_file);
                     /*if (is_array($response) && isset($response['success']) && !$response['success']) {
                     			return $other_data;
                     		}*/
                     if (!empty($other_data)) {
                         $other_data .= '||';
                     }
                     $other_data .= $entry;
                     $is_import = true;
                     break;
                 } else {
                     return 'done';
                 }
             }
         }
         closedir($handle);
     } else {
         return 'done';
     }
     if ($is_import) {
         return $other_data;
     }
     return 'done';
 }
开发者ID:adwleg,项目名称:site,代码行数:37,代码来源:g5plus_import_class.php


示例2: ot_type_revslider_select

 function ot_type_revslider_select($args = array())
 {
     extract($args);
     $has_desc = $field_desc ? true : false;
     echo '<div class="format-setting type-revslider-select ' . ($has_desc ? 'has-desc' : 'no-desc') . '">';
     echo $has_desc ? '<div class="description">' . htmlspecialchars_decode($field_desc) . '</div>' : '';
     echo '<div class="format-setting-inner">';
     // Add This only if RevSlider is Activated
     if (class_exists('RevSliderAdmin')) {
         echo '<select name="' . esc_attr($field_name) . '" id="' . esc_attr($field_id) . '" class="option-tree-ui-select ' . $field_class . '">';
         /* get revolution array */
         $slider = new RevSlider();
         $arrSliders = $slider->getArrSlidersShort();
         /* has slides */
         if (!empty($arrSliders)) {
             echo '<option value="">-- ' . __('Choose One', 'option-tree') . ' --</option>';
             foreach ($arrSliders as $rev_id => $rev_slider) {
                 echo '<option value="' . esc_attr($rev_id) . '"' . selected($field_value, $rev_id, false) . '>' . esc_attr($rev_slider) . '</option>';
             }
         } else {
             echo '<option value="">' . __('No Sliders Found', 'option-tree') . '</option>';
         }
         echo '</select>';
     } else {
         echo '<span style="color: red;">' . __('Sorry! Revolution Slider is not Installed or Activated', 'ventus') . '</span>';
     }
     echo '</div>';
     echo '</div>';
 }
开发者ID:adampdarcy,项目名称:paola,代码行数:29,代码来源:ot-themeoptions.php


示例3: add_eg_additional_meta_field

    /**
     * Adds custom meta field into the essential grid meta box for post/pages
     */
    public function add_eg_additional_meta_field($values)
    {
        $sld = new RevSlider();
        $sliders = $sld->getArrSliders();
        $shortcodes = array();
        if (!empty($sliders)) {
            $first = true;
            foreach ($sliders as $slider) {
                $name = $slider->getParam('shortcode', 'false');
                if ($name != 'false') {
                    $shortcodes[$slider->getID()] = $name;
                    $first = false;
                }
            }
        }
        $selected_slider = isset($values['eg_sources_revslider']) ? $values['eg_sources_revslider'] : '';
        if ($selected_slider == '') {
            $selected_slider[0] = '';
        }
        ?>

		<p>
			<strong style="font-size:14px"><?php 
        _e('Choose Revolution Slider', REVSLIDER_TEXTDOMAIN);
        ?>
</strong>
		</p>
		<p>
			<select name="eg_sources_revslider" id="eg_sources_revslider">
				<option value=""<?php 
        selected($selected_slider[0], '');
        ?>
><?php 
        _e('--- Choose Slider ---', REVSLIDER_TEXTDOMAIN);
        ?>
</option>
				<?php 
        if (!empty($shortcodes)) {
            foreach ($shortcodes as $id => $name) {
                ?>

						<option value="<?php 
                echo $id;
                ?>
"<?php 
                selected($selected_slider[0], $id);
                ?>
><?php 
                echo $name;
                ?>
</option>
						<?php 
            }
        }
        ?>

			</select>
		</p>
		<?php 
    }
开发者ID:VLabsInc,项目名称:WordPressPlatforms,代码行数:63,代码来源:extension.class.php


示例4: zenite_contingut_stripe

function zenite_contingut_stripe($post)
{
    // Use nonce for verification
    wp_nonce_field(plugin_basename(__FILE__), 'zenite_noncename');
    // The actual fields for data entry
    echo '<label for="zenite_white">';
    _e("Show WhiteStripe?:", 'zenite');
    echo '</label> ';
    echo '<input type="checkbox" id="zenite_white" name="zenite_white" value="on"';
    if (get_post_meta($post->ID, 'zenite_whitestripe', true) == 'on') {
        echo ' checked="checked"';
    }
    echo ' /><br><br>';
    echo '<label for="zenite_slider">';
    _e("Slider:", 'zenite');
    echo '</label> ';
    echo '<select name="zenite_slider" id="zenite_slider"><option value="0">No Slider</option>';
    if (class_exists('RevSlider')) {
        $slider = new RevSlider();
        $arrSliders = $slider->getArrSliders();
        foreach ($arrSliders as $revSlider) {
            //		$revolutionslider[$revSlider->getAlias()] = $revSlider->getTitle();
            echo '<option value="' . $revSlider->getAlias() . '"';
            if (get_post_meta($post->ID, 'zenite_slider', true) == $revSlider->getAlias()) {
                echo " selected='selected'";
            }
            echo '>' . $revSlider->getTitle() . '</option>';
        }
    }
    echo '</select>';
}
开发者ID:JalpMi,项目名称:v2contact,代码行数:31,代码来源:panels.php


示例5: register

 function register()
 {
     // Init Post Type
     $post = new SpyropressCustomPostType('Page');
     $menus = wp_get_nav_menus();
     $menu_options = array();
     if (isset($menus) && count($menus) > 0) {
         foreach ($menus as $menu) {
             $menu_options[$menu->term_id] = $menu->name;
         }
     }
     // Add Meta Boxes
     $meta_fields['options'] = array(array('label' => __('Slider', 'spyropress'), 'type' => 'heading', 'slug' => 'options'), array('label' => __('OnePage Navigation Menu', 'spyropress'), 'id' => 'onepage_menu', 'type' => 'select', 'class' => 'page_template one-page-php', 'options' => $menu_options), array('label' => __('Slider', 'spyropress'), 'type' => 'sub_heading'), array('label' => __('Slider Type', 'spyropress'), 'id' => 'slider', 'type' => 'select', 'class' => 'enable_changer', 'options' => array('nivo' => __('Nivo Slider', 'spyropress'), 'rev' => __('Revolution Slider', 'spyropress'))), array('label' => __('Nivo Slider', 'spyropress'), 'id' => 'nivo_slider', 'type' => 'select', 'class' => 'slider nivo', 'options' => spyropress_get_sliders()));
     if (class_exists('RevSlider')) {
         $slider = new RevSlider();
         $arrSliders = $slider->getArrSlidersShort();
         $meta_fields['options'][] = array('label' => __('Revolution Slider', 'spyropress'), 'id' => 'rev_slider', 'type' => 'select', 'class' => 'slider rev', 'options' => $arrSliders);
         $meta_fields['options'][] = array('label' => __('Revolution Slider Skin', 'spyropress'), 'id' => 'rev_slider_skin', 'type' => 'select', 'class' => 'slider rev', 'options' => array('dark' => __('Dark', 'spyropress'), 'light' => __('Light', 'spyropress'), 'full' => __('FullScreen', 'spyropress'), 'dark dark-video' => __('Video - Dark', 'spyropress'), 'light dark-light' => __('Video - Light', 'spyropress')), 'std' => 'dark');
     }
     $meta_fields['options'][] = array('label' => __('Header', 'spyropress'), 'type' => 'sub_heading');
     $meta_fields['options'][] = array('label' => __('Header Type', 'spyropress'), 'id' => 'top_header', 'type' => 'select', 'class' => 'enable_changer', 'options' => array('none' => __('None', 'spyropress'), 'default' => __('Default', 'spyropress'), 'custom' => __('Custom Header', 'spyropress')), 'std' => 'default');
     $meta_fields['options'][] = array('label' => __('Custom Header Bucket', 'spyropress'), 'id' => 'bucket', 'type' => 'select', 'class' => 'top_header custom', 'desc' => __('Either use Bucket or Content', 'spyropress'), 'options' => spyropress_get_buckets());
     $meta_fields['options'][] = array('label' => __('Custom Header Content', 'spyropress'), 'id' => 'header_content', 'type' => 'editor', 'desc' => __('Either use Bucket or Content', 'spyropress'), 'class' => 'top_header custom');
     $meta_fields['options'][] = array('label' => __('Custom Header Background', 'spyropress'), 'id' => 'background', 'type' => 'background', 'class' => 'top_header custom');
     $meta_fields['options'][] = array('label' => __('Top Border color', 'spyropress'), 'id' => 'border_top', 'type' => 'colorpicker', 'class' => 'top_header custom');
     $meta_fields['options'][] = array('label' => __('Bottom Border color', 'spyropress'), 'id' => 'border_bottom', 'type' => 'colorpicker', 'class' => 'top_header custom');
     $meta_fields['options'][] = array('label' => __('Layout', 'spyropress'), 'type' => 'sub_heading');
     $meta_fields['options'][] = array('label' => __('Layout Type', 'spyropress'), 'id' => 'layout_type', 'type' => 'select', 'options' => array('full' => __('Full Width', 'spyropress'), 'left' => __('Left Sidebar', 'spyropress'), 'right' => __('Right Sidebar', 'spyropress')), 'std' => 'full');
     $post->add_meta_box('page_options', __('Page Options', 'spyropress'), $meta_fields, '_page_options', false, 'normal', 'high');
 }
开发者ID:rinodung,项目名称:myfreetheme,代码行数:30,代码来源:page-init.php


示例6: my_print_shortcodes_in_js

    public static function my_print_shortcodes_in_js()
    {
        $sld = new RevSlider();
        $sliders = $sld->getArrSliders();
        $shortcodes = '';
        if (!empty($sliders)) {
            $first = true;
            foreach ($sliders as $slider) {
                $shortcode = $slider->getParam('shortcode', 'false');
                if ($shortcode != 'false') {
                    if (!$first) {
                        $shortcodes .= ',';
                    }
                    $shortcodes .= "'" . $shortcode . "'";
                    $first = false;
                }
            }
        }
        ?>

		<script type="text/javascript">
			var revslider_shortcodes = [<?php 
        echo $shortcodes;
        ?>
];
		</script>
		<?php 
    }
开发者ID:IDOAgency,项目名称:PAHClinic,代码行数:28,代码来源:revslider_tinybox.class.php


示例7: getRevSlider

 public function getRevSlider()
 {
     if (!$this->slider && ($alias = $this->getParam('activeRevSlider'))) {
         $this->slider = new RevSlider();
         $this->slider->initByMixed($alias);
     }
     return $this->slider;
 }
开发者ID:nikolaskarica,项目名称:bds-alliance,代码行数:8,代码来源:revolution_slider.php


示例8: revSliderCharityDataImport

 public function revSliderCharityDataImport() {
 	if (class_exists('RevSlider')) {
 		$slider = new RevSlider();
 		$response = $slider->importSliderFromPost(true, true, CHY_THEME_DIR . '/vendor/data/home_slder2.zip');
 		$response = $slider->importSliderFromPost(true, true, CHY_THEME_DIR . '/vendor/data/home_slder3.zip');
 		$response = $slider->importSliderFromPost(true, true, CHY_THEME_DIR . '/vendor/data/home_slder1.zip');
 		$response = $slider->importSliderFromPost(true, true, CHY_THEME_DIR . '/vendor/data/ShopLandingSlider.zip');
 	}
 }
开发者ID:kautzar,项目名称:drpp4,代码行数:9,代码来源:oneclick.php


示例9: __construct

 /**
  * Constructor
  */
 public function __construct()
 {
     parent::__construct();
     $revSliderAdmin = Mage::getSingleton('RevSliderAdmin');
     $revSliderAdmin->requireSettings("slider_settings");
     $settingsMain = $revSliderAdmin->getSettings("slider_main");
     $settingsParams = $revSliderAdmin->getSettings("slider_params");
     $settingsSliderMain = new RevSliderSettingsProduct();
     $settingsSliderParams = new UniteSettingsProductSidebarRev();
     //get taxonomies with cats
     $postTypesWithCats = RevOperations::getPostTypesWithCatsForClient();
     $jsonTaxWithCats = UniteFunctionsRev::jsonEncodeForClientSide($postTypesWithCats);
     //check existing slider data:
     $sliderID = $this->getRequest()->getParam('id');
     if (!empty($sliderID)) {
         $slider = new RevSlider();
         $slider->initByID($sliderID);
         //get setting fields
         $settingsFields = $slider->getSettingsFields();
         $arrFieldsMain = $settingsFields["main"];
         $arrFieldsParams = $settingsFields["params"];
         //modify arrows type for backword compatability
         $arrowsType = UniteFunctionsRev::getVal($arrFieldsParams, "navigation_arrows");
         switch ($arrowsType) {
             case "verticalcentered":
                 $arrFieldsParams["navigation_arrows"] = "solo";
                 break;
         }
         //set custom type params values:
         $settingsMain = RevSliderSettingsProduct::setSettingsCustomValues($settingsMain, $arrFieldsParams, $postTypesWithCats);
         //set setting values from the slider
         $settingsMain->setStoredValues($arrFieldsParams);
         $settingsParams->setStoredValues($arrFieldsParams);
         //update short code setting
         $shortcode = $slider->getShortcode();
         $settingsMain->updateSettingValue("shortcode", htmlentities($shortcode));
         $linksEditSlides = $this->helper("adminhtml")->getUrl('adminhtml/nwdrevslider/slides/id/' . $sliderID);
         $settingsSliderParams->init($settingsParams);
         $settingsSliderMain->init($settingsMain);
         $settingsSliderParams->isAccordion(true);
         $this->assign('sliderID', $sliderID);
         $this->assign('linksEditSlides', $linksEditSlides);
         $this->assign('arrFieldsParams', $arrFieldsParams);
         $this->setTemplate('nwdthemes/revslider/templates/slider_edit.phtml');
     } else {
         //set custom type params values:
         $settingsMain = RevSliderSettingsProduct::setSettingsCustomValues($settingsMain, array(), $postTypesWithCats);
         $settingsSliderParams->init($settingsParams);
         $settingsSliderMain->init($settingsMain);
         $settingsSliderParams->isAccordion(true);
         $this->setTemplate('nwdthemes/revslider/templates/slider_new.phtml');
     }
     $this->assign('sliderTemplate', $this->_sliderTemplate);
     $this->assign('settingsSliderMain', $settingsSliderMain);
     $this->assign('settingsSliderParams', $settingsSliderParams);
     $this->assign('jsonTaxWithCats', $jsonTaxWithCats);
 }
开发者ID:perseusl,项目名称:kingdavid,代码行数:60,代码来源:Edit.php


示例10: yit_get_revolution_sliders

function yit_get_revolution_sliders()
{
    global $wpdb;
    if (!yit_if_thereis_revslider()) {
        return array();
    }
    $tableName = GlobalsRevSlider::$table_sliders;
    $slider = new RevSlider();
    return $slider->getArrSlidersShort();
}
开发者ID:zgomotos,项目名称:Bazar,代码行数:10,代码来源:config.php


示例11: wbc_extended_example

 function wbc_extended_example($demo_active_import, $demo_directory_path)
 {
     reset($demo_active_import);
     $current_key = key($demo_active_import);
     /************************************************************************
      * Import slider(s) for the current demo being imported
      *************************************************************************/
     if (class_exists('RevSlider')) {
         //If it's demo3 or demo5
         $wbc_sliders_array = array('demo1' => 'newslider2014.zip');
         if (isset($demo_active_import[$current_key]['directory']) && !empty($demo_active_import[$current_key]['directory']) && array_key_exists($demo_active_import[$current_key]['directory'], $wbc_sliders_array)) {
             $wbc_slider_import = $wbc_sliders_array[$demo_active_import[$current_key]['directory']];
             if (file_exists($demo_directory_path . $wbc_slider_import)) {
                 $slider = new RevSlider();
                 $slider->importSliderFromPost(true, true, $demo_directory_path . $wbc_slider_import);
             }
         }
     }
     /************************************************************************
      * Setting Menus
      *************************************************************************/
     // If it's demo1 - demo6
     $wbc_menu_array = array('demo1');
     if (isset($demo_active_import[$current_key]['directory']) && !empty($demo_active_import[$current_key]['directory']) && in_array($demo_active_import[$current_key]['directory'], $wbc_menu_array)) {
         $top_menu = get_term_by('name', 'Top Menu', 'nav_menu');
         $main_menu = get_term_by('name', 'Header Menu', 'nav_menu');
         $footer_menu = get_term_by('name', 'Footer Menu', 'nav_menu');
         if (isset($top_menu->term_id)) {
             set_theme_mod('nav_menu_locations', array('top-menu' => $top_menu->term_id, 'primary-menu' => $main_menu->term_id, 'footer-menu' => $footer_menu->term_id));
         }
     }
     /************************************************************************
      * Set HomePage
      *************************************************************************/
     // array of demos/homepages to check/select from
     $wbc_home_pages = array('demo1' => 'Home');
     $wbc_blog_pages = array('demo1' => 'Blog');
     if (isset($demo_active_import[$current_key]['directory']) && !empty($demo_active_import[$current_key]['directory']) && array_key_exists($demo_active_import[$current_key]['directory'], $wbc_home_pages)) {
         $page = get_page_by_title($wbc_home_pages[$demo_active_import[$current_key]['directory']]);
         if (isset($page->ID)) {
             update_option('page_on_front', $page->ID);
             update_option('show_on_front', 'page');
             //Update Widgets Switch to On
             $all_widgets_on = 'a:34:{s:6:"button";b:1;s:10:"google-map";b:1;s:5:"image";b:1;s:6:"slider";b:1;s:13:"post-carousel";b:1;s:6:"editor";b:1;s:12:"alert-widget";b:1;s:14:"counter-widget";b:1;s:21:"featured-block-widget";b:1;s:19:"gallery-grid-widget";b:1;s:4:"icon";b:1;s:15:"carousel-widget";b:1;s:17:"posts-list-widget";b:1;s:18:"progressbar-widget";b:1;s:19:"sermons-list-widget";b:1;s:21:"sermons-albums-widget";b:1;s:17:"staff-grid-widget";b:1;s:13:"spacer-widget";b:1;s:11:"tabs-widget";b:1;s:8:"taxonomy";b:1;s:13:"toggle-widget";b:1;s:11:"testimonial";b:1;s:30:"upcoming-events-listing-widget";b:1;s:5:"video";b:1;s:14:"simple-masonry";b:1;s:20:"social-media-buttons";b:1;s:11:"price-table";b:1;s:13:"layout-slider";b:1;s:10:"image-grid";b:1;s:4:"hero";b:1;s:8:"headline";b:1;s:8:"features";b:1;s:7:"contact";b:1;s:3:"cta";b:1;}';
             $all_widgets_on = unserialize($all_widgets_on);
             update_option('siteorigin_widgets_active', $all_widgets_on);
         }
     }
     if (isset($demo_active_import[$current_key]['directory']) && !empty($demo_active_import[$current_key]['directory']) && array_key_exists($demo_active_import[$current_key]['directory'], $wbc_blog_pages)) {
         $bpage = get_page_by_title($wbc_blog_pages[$demo_active_import[$current_key]['directory']]);
         if (isset($bpage->ID)) {
             update_option('page_for_posts', $bpage->ID);
         }
     }
 }
开发者ID:jesusmarket,项目名称:jesusmarket,代码行数:55,代码来源:extension_wbc_importer.php


示例12: toOptionArray

 public function toOptionArray()
 {
     new RevSliderAdmin();
     $slider = new RevSlider();
     $arrSliders = $slider->getArrSliders();
     $options = array();
     foreach ($arrSliders as $item) {
         $options[] = array('value' => $item->getAlias(), 'label' => $item->getAlias());
     }
     return $options;
 }
开发者ID:perseusl,项目名称:kingdavid,代码行数:11,代码来源:Revslider.php


示例13: ac_get_revsliders

function ac_get_revsliders()
{
    $rev_sliders = array();
    if (ac_revslider_is_installed()) {
        $slider = new RevSlider();
        $arrSliders = $slider->getArrSliders();
        foreach ($arrSliders as $arrSlider) {
            $rev_sliders[$arrSlider->getAlias()] = $arrSlider->getTitle();
        }
    }
    return $rev_sliders;
}
开发者ID:Jhorton4,项目名称:Bohldfeys_Portfolio,代码行数:12,代码来源:ac-sliders.php


示例14: import_revsliders

 public function import_revsliders($file)
 {
     if (!file_exists($file)) {
         return 'Revolution Slider file not found';
         return;
     }
     if (class_exists('RevSlider')) {
         ob_start();
         $rev = new RevSlider();
         $response = $rev->importSliderFromPost(false, false, $file);
         ob_end_clean();
         return 'Revolution Slider imported';
     }
 }
开发者ID:AlchemyMomentum,项目名称:public_html,代码行数:14,代码来源:radium-importer.php


示例15: x_revolution_slider_get_slider_meta

function x_revolution_slider_get_slider_meta()
{
    $rs = new RevSlider();
    $sliders = $rs->getArrSliders();
    $data = array();
    foreach ($sliders as $s) {
        $key = 'x-slider-rs-' . $s->getID();
        $data[$key]['id'] = $s->getID();
        $data[$key]['slug'] = $s->getAlias();
        $data[$key]['name'] = $s->getTitle();
        $data[$key]['source'] = 'Revolution Slider';
    }
    return $data;
}
开发者ID:skywindzz,项目名称:blue_leopard,代码行数:14,代码来源:revolution-slider.php


示例16: controls

 public function controls()
 {
     $found = array();
     if (class_exists('RevSlider')) {
         $new_rev_slider = new RevSlider();
         $rev_sliders = $new_rev_slider->getArrSliders();
         foreach ($rev_sliders as $rs) {
             $found[] = array('value' => $rs->getAlias(), 'label' => $rs->getTitle());
         }
     }
     if (empty($found)) {
         $found[] = array('value' => 'none', 'label' => __('No Slider Available', csl18n()), 'disabled' => true);
     }
     $this->addControl('alias', 'select', __('Select Slider', csl18n()), __('Choose from Revolution Slider elements that have already been created.', csl18n()), $found[0]['value'], array('choices' => $found));
 }
开发者ID:nayabbukhari,项目名称:circulocristiano,代码行数:15,代码来源:revolution-slider.php


示例17: import_revslider

 function import_revslider($folder = '')
 {
     if (!class_exists('RevSliderAdmin')) {
         require_once RS_PLUGIN_PATH . '/admin/revslider-admin.class.php';
     }
     $rev_files = glob(get_template_directory() . '/library/import/files/' . $folder . '/revslider/*.zip');
     if (!empty($rev_files)) {
         foreach ($rev_files as $rev_file) {
             $_FILES['import_file']['error'] = UPLOAD_ERR_OK;
             $_FILES['import_file']['tmp_name'] = $rev_file;
             $slider = new RevSlider();
             $slider->importSliderFromPost(true, 'none');
         }
     }
 }
开发者ID:love4code,项目名称:originalContracting,代码行数:15,代码来源:import.php


示例18: form

 /**
  * 
  * the form
  */
 public function form($instance)
 {
     $slider = new RevSlider();
     $arrSliders = $slider->getArrSlidersShort();
     $sliderID = UniteFunctionsRev::getVal($instance, "rev_slider");
     if (empty($arrSliders)) {
         echo __("No sliders found, Please create a slider", tk_theme_name);
     } else {
         $field = "rev_slider";
         $fieldID = $this->get_field_id($field);
         $fieldName = $this->get_field_name($field);
         $select = UniteFunctionsRev::getHTMLSelect($arrSliders, $sliderID, 'name="' . $fieldName . '" id="' . $fieldID . '"', true);
     }
     echo "Choose slider: ";
     echo $select;
 }
开发者ID:rohichurch,项目名称:rohichurch-wp,代码行数:20,代码来源:revslider_widget.class.php


示例19: addShortcodeSettings

 /**
  * Mapping settings for lean method.
  *
  * @since 4.9
  *
  * @param $tag
  *
  * @return array
  */
 public function addShortcodeSettings($tag)
 {
     $slider = new RevSlider();
     $arrSliders = $slider->getArrSliders();
     $revsliders = array();
     if ($arrSliders) {
         foreach ($arrSliders as $slider) {
             /** @var $slider RevSlider */
             $revsliders[$slider->getTitle()] = $slider->getAlias();
         }
     } else {
         $revsliders[__('No sliders found', 'js_composer')] = 0;
     }
     // Add fixes for frontend editor to regenerate id
     return array('base' => $tag, 'name' => __('Revolution Slider', 'js_composer'), 'icon' => 'icon-wpb-revslider', 'category' => __('Content', 'js_composer'), 'description' => __('Place Revolution slider', 'js_composer'), 'params' => array(array('type' => 'textfield', 'heading' => __('Widget title', 'js_composer'), 'param_name' => 'title', 'description' => __('Enter text used as widget title (Note: located above content element).', 'js_composer')), array('type' => 'dropdown', 'heading' => __('Revolution Slider', 'js_composer'), 'param_name' => 'alias', 'admin_label' => true, 'value' => $revsliders, 'save_always' => true, 'description' => __('Select your Revolution Slider.', 'js_composer')), array('type' => 'textfield', 'heading' => __('Extra class name', 'js_composer'), 'param_name' => 'el_class', 'description' => __('Style particular content element differently - add a class name and refer to it in custom CSS.', 'js_composer'))));
 }
开发者ID:k2jysy,项目名称:wedev,代码行数:25,代码来源:class-vc-vendor-revslider.php


示例20: import_sliders

 private function import_sliders()
 {
     $dir = opendir($this->dir);
     ob_start();
     while ($file = readdir($dir)) {
         if ($file != '.' && $file != '..' && preg_match('/\\.zip$/', $file)) {
             $filepath = $this->dir . '/' . $file;
             if (!isset($_FILES["import_file"])) {
                 $_FILES["import_file"] = array();
             }
             $_FILES["import_file"]["tmp_name"] = $filepath;
             $slider = new RevSlider();
             $response = $slider->importSliderFromPost();
         }
     }
     ob_end_clean();
 }
开发者ID:amitmula,项目名称:amitandaastha.in,代码行数:17,代码来源:importer.php



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


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP RevSliderBase类代码示例发布时间:2022-05-23
下一篇:
PHP RevSlide类代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap