$32 GRAYBYTE WORDPRESS FILE MANAGER $25

SERVER : premium201.web-hosting.com #1 SMP Wed Mar 26 12:08:09 UTC 2025
SERVER IP : 172.67.217.254 | ADMIN IP 216.73.216.180
OPTIONS : CRL = ON | WGT = ON | SDO = OFF | PKEX = OFF
DEACTIVATED : mail

/home/bravrvjk/cepurhuye.rw/wp-content/plugins/bopea-function/inc/

HOME
Current File : /home/bravrvjk/cepurhuye.rw/wp-content/plugins/bopea-function/inc//cb.php
<?php
if ( ! defined( 'ABSPATH' ) ) exit;
	class bopea_Meta_Box{
		protected $_metabox;
		function __construct( $metabox ) {
			if ( !is_admin() ) return;
			$this->_metabox = $metabox;
			add_action( 'admin_menu', array( &$this, 'add' ) );
			add_action( 'save_post', array( &$this, 'save' ) );
		}
		function add() {
			$this->_metabox['context'] = empty($this->_metabox['context']) ? 'normal' : $this->_metabox['context'];
			$this->_metabox['priority'] = empty($this->_metabox['priority']) ? 'high' : $this->_metabox['priority'];

			foreach ( $this->_metabox['pages'] as $page ) {
				add_meta_box( $this->_metabox['id'], $this->_metabox['title'], array(&$this, 'show'), $page, $this->_metabox['context'], $this->_metabox['priority']) ;
			}
		}
		function show() {
			global $post;
			echo '<input type="hidden" name="wp_meta_box_nonce" value="', wp_create_nonce( basename(__FILE__) ), '" />';
			echo '<div class="jl_tabbox_wrapper">';
			if ( get_post_type( get_the_ID() ) == 'post' ) {
			?>
			<div class="jl_nab_tab">
	        <a id="options-group-1-tab" class="generalsetting-tab" href="#options-group-1">Post Settings</a>
	        <a id="options-group-2-tab" class="generalsetting-tab" href="#options-group-2">Post Review</a>
	        <a id="options-group-3-tab" class="generalsetting-tab" href="#options-group-3">Post Format gallery</a>
	        <a id="options-group-4-tab" class="generalsetting-tab" href="#options-group-4">Post Format quote</a>
	        <a id="options-group-5-tab" class="generalsetting-tab" href="#options-group-5">Post Format video</a>
	        <a id="options-group-6-tab" class="generalsetting-tab" href="#options-group-6">Post Format audio</a>
	        <a id="options-group-7-tab" class="generalsetting-tab" href="#options-group-7">Sponsored Post</a>
	        <a id="options-group-8-tab" class="generalsetting-tab" href="#options-group-8">Sources & Via</a>
	        </div>
			<?php }
				if ( get_post_type( get_the_ID() ) == 'page' ) {
			?>
			<div class="jl_nab_tab">
	        <a id="options-group-1-tab" class="generalsetting-tab" href="#options-group-1">Page Settings</a>
	        <a id="options-group-2-tab" style="display:none;" class="generalsetting-tab" href="#options-group-2">Home Post Pagination</a>
	        </div>
			<?php }
			foreach ( $this->_metabox['fields'] as $field ) {
				if ( !isset( $field['name'] ) ) $field['name'] = '';
				if ( !isset( $field['desc'] ) ) $field['desc'] = '';
				if ( !isset( $field['std'] ) ) $field['std'] = '';
				$meta = get_post_meta($post->ID, $field['id'], true);
				$meta = ( '' === $meta || array() === $meta ) ? $field['std'] : $meta;
				echo '<div class="jl_trow group" id="'.$field['id'].'">';
					echo '<div class="jl_th"><label for="input-'.$field['id'].'">'.$field['label'].'</label></div>';

					echo '<div class="jl_td">';
					switch($field['type']) {
						case 'text':
							echo '<input type="text" name="'.$field['id'].'" id="input-'.$field['id'].'" value="'.$meta.'" size="64" />';
							echo '<br /><span style="margin-top: 0px; display: block;" class="description">'.$field['desc'].'</span>';
							break;
						case 'image':
							echo '<input class="jelly_cat_header_image_id '.$field['id'].'" type="hidden" name="'.$field['id'].'" value="'.$meta.'" size="64" />';
							echo '<span style="margin-top: 0px; display: block;" class="description">'.$field['desc'].'</span>';
							echo '<div class="jelly_cat_header '.$field['id'].'" style="margin-bottom:10px; width: 100px; white-space: nowrap;">';
							if(!empty($meta)){
								$review_img = wp_get_attachment_image_src($meta, 'thumbnail');
								$attach_type = wp_get_attachment_url( $meta );
								if (str_contains($attach_type, '.mp4')){
									echo '<img src="'.esc_url(BOPEA_ADDONS_ASSETS.'images/video.png').'" style="max-width: 70px;"/>';
									echo '<p class="media_url">'.$attach_type.'</p>';
								}elseif(str_contains($attach_type, '.mp3')){
									echo '<img src="'.esc_url(BOPEA_ADDONS_ASSETS.'images/mp3.png').'" style="max-width: 70px;"/>';
									echo '<p class="media_url">'.$attach_type.'</p>';
								}else{
									if(!empty($review_img)){
										echo '<img src="'.$review_img[0].'" style="max-width: 70px;"/>';
										echo '<p class="media_url"></p>';
									}
								}
							}else{
							echo '<img src="'.esc_url(BOPEA_ADDONS_ASSETS.'images/none_image.png').'" style="max-width: 70px;"/>';
							echo '<p class="media_url"></p>';
							}
							echo'</div>';
							echo '<button type="submit" class="jl_meta_media jladdbtn" id="'.$field['id'].'">Add Media</button>';
							echo '<button type="submit" class="jl_remove_media jlremovebtn" id="'.$field['id'].'">Remove Media</button>';
							break;
						case 'color':
							echo '<input type="text" class="colorpicker" name="'.$field['id'].'" id="input-'.$field['id'].'" value="'.$meta.'" size="64" />';
							echo '<br /><span style="margin-top: 0px; display: block;" class="description">'.$field['desc'].'</span>';
							break;
						case 'line':
							echo '<span style="margin-top: 0px; display: block;" class="description">'.$field['desc'].'</span>';
							break;
						case 'topen':
							echo '<div id="'.$field['id'].'">';
							break;
						case 'tclose':
							echo '</div>';
							break;
						case 'gallery':
							echo '<br /><span style="margin-top: 0px; display: block;" class="description">'.$field['desc'].'</span>';
							?>
							<ul class="jlmedia-gallery-images-holder clearfix">
								<?php
								$image_gallery_val = get_post_meta( $post->ID, $field['id'], true);
								if($image_gallery_val!='' ) $image_gallery_array=explode(',',$image_gallery_val);
								if(isset($image_gallery_array) && count($image_gallery_array)!=0):
									foreach($image_gallery_array as $gimg_id):
										$gimage_wp = wp_get_attachment_image_src($gimg_id,'thumbnail', true);
										echo '<li class="jlmedia-gallery-image-holder"><img src="'.esc_url($gimage_wp[0]).'"/></li>';
									endforeach;
								endif;
								?>
							</ul>
							<input type="hidden" value="<?php echo esc_attr($image_gallery_val); ?>" id="<?php echo esc_attr( $field['id']) ?>" name="<?php echo esc_attr( $field['id']) ?>">
							<div class="jlmedia-gallery-uploader">
								<a class="jlmedia-gallery-upload-btn btn btn-sm btn-primary"
								   href="javascript:void(0)"><?php esc_html_e('Upload or Edit', 'bopea-function'); ?></a>
								<a class="jlmedia-gallery-clear-btn btn btn-sm btn-default pull-right"
								   href="javascript:void(0)"><?php esc_html_e('Remove All', 'bopea-function'); ?></a>
							</div>
							<?php
							break;
						case 'textarea':
							echo '<textarea name="'.$field['id'].'" id="input-'.$field['id'].'" cols="60" rows="10" style="width: 100%;">'.$meta.'</textarea>';
							echo '<br /><span style="margin-top: 0px; display: block;" class="description">'.$field['desc'].'</span>';
							break;
						case 'checkbox':
							echo '<input style="margin-right: 10px;" type="checkbox" name="'.$field['id'].'" id="input-'.$field['id'].'" ',$meta ? ' checked="checked"' : '','/>';
							echo '<label for="input-'.$field['id'].'">'.$field['desc'].'</label>';
							break;
						case 'select':
							echo '<select name="'.$field['id'].'" id="input-'.$field['id'].'">';
							foreach ($field['options'] as $key => $val) {
								echo '<option', $meta == $key ? ' selected="selected"' : '', ' value="'.$key.'">'.$val.'</option>';
							}
							echo '</select><br /><span style="margin-top: 0px; display: block;" class="description">'.$field['desc'].'</span>';
							break;
						case 'radio':
							foreach ( $field['options'] as $key => $val ) {
								echo '<input type="radio" name="'.$field['id'].'" id="input-'.$field['id'].'_'.$key.'" value="'.$key.'" ',$meta == $key ? ' checked="checked"' : '',' />';
								echo '<label for="'.$field['id'].'_'.$key.'">'.$val.'</label><br>';
							}
							break;
						case 'rating_criteria':
                            $rows = array();
                            if($meta) $rows = $meta;
                            $c = 0;
                            if ( count( $rows ) > 0 ) {
                                foreach( $rows as $row ) {
                                    if ( isset( $row['c_label'] ) || isset( $row['score'] ) ) {
                                        echo '
                                        <p class="rating_row jl_cus_repeater" style="margin-bottom:10px;">
                                        <label for="'.$field['id'].'['.$c.'][c_label]">Label :</label>
                                        <input type="text" name="'.$field['id'].'['.$c.'][c_label]" value="'.$row['c_label'].'" />
                                        <label for="'.$field['id'].'['.$c.'][score]">Score :</label>
                                        <input type="text" name="'.$field['id'].'['.$c.'][score]" value="'.$row['score'].'" />
                                        <a class="remove_review button-secondary">Remove</a>
                                        </p>';
                                        $c = $c + 1;
                                    }
                                }
                            }
                            echo '<span id="criteria-placeholder"></span>';
                            echo '<a class="add-criteria button-primary" href="#">Add Criteria</a>';
                            echo '<br /><span style="margin-top: 0px; display: block;" class="description">'.$field['desc'].'</span>';
                            ?>
                            <script>
                                var $ = jQuery.noConflict();
                                $(document).ready(function() {
                                    var count = <?php echo esc_attr($c); ?>;
                                    $('.add-criteria').click(function() {
                                        count = count + 1;
                                        $('#criteria-placeholder').append('<p class="rating_row jl_cus_repeater" style="margin-bottom:10px;"><label for="<?php echo esc_attr($field['id']); ?>['+count+'][c_label]">Label : </label><input type="text" name="<?php echo esc_attr($field['id']); ?>['+count+'][c_label]" value="" /><label for="<?php echo esc_attr($field['id']); ?>['+count+'][score]"> Score : </label><input type="text" name="<?php echo esc_attr($field['id']); ?>['+count+'][score]" value="" /> <a class="remove_review button-secondary">Remove</a></p>');
                                        return false;
                                    });

                                    $('body').on('click', '.remove_review', function(){
                                        $(this).parent('.rating_row').remove();
                                    });

                                });
                            </script>
                            <?php
                        break;
                        case 'source_options':
                            $rows = array();
                            if($meta) $rows = $meta;
                            $c = 0;
                            if ( count( $rows ) > 0 ) {
                                foreach( $rows as $row ) {
                                    if ( isset( $row['c_label'] ) || isset( $row['url'] ) ) {
                                        echo '
                                        <p class="opt-source-row jl_cus_repeater" style="margin-bottom:10px;">
                                        <label for="'.$field['id'].'['.$c.'][c_label]">Label :</label>
                                        <input type="text" name="'.$field['id'].'['.$c.'][c_label]" value="'.$row['c_label'].'" />
                                        <label for="'.$field['id'].'['.$c.'][url]">URL :</label>
                                        <input type="text" name="'.$field['id'].'['.$c.'][url]" value="'.$row['url'].'" />
                                        <a class="opt-remove-source button-secondary">Remove</a>
                                        </p>';
                                        $c = $c + 1;
                                    }
                                }
                            }
                            echo '<span id="opt-source-placeholder"></span>';
                            echo '<a class="add-opt-source button-primary" href="#">Add Post Source</a>';
                            echo '<br /><span style="margin-top: 0px; display: block;" class="description">'.$field['desc'].'</span>';
                            ?>
                            <script>
                                var $ = jQuery.noConflict();
                                $(document).ready(function() {
                                    var count_source = <?php echo esc_attr($c); ?>;
                                    $('.add-opt-source').click(function() {
                                        count_source = count_source + 1;
                                        $('#opt-source-placeholder').append('<p class="opt-source-row jl_cus_repeater" style="margin-bottom:10px;"><label for="<?php echo esc_attr($field['id']); ?>['+count_source+'][c_label]">Label : </label><input type="text" name="<?php echo esc_attr($field['id']); ?>['+count_source+'][c_label]" value="" /><label for="<?php echo esc_attr($field['id']); ?>['+count_source+'][url]"> URL : </label><input type="text" name="<?php echo esc_attr($field['id']); ?>['+count_source+'][url]" value="" /> <a class="opt-remove-source button-secondary">Remove</a></p>');
                                        return false;
                                    });

                                    $('body').on('click', '.opt-remove-source', function(){
                                        $(this).parent('.opt-source-row').remove();
                                    });

                                });
                            </script>
                            <?php
                        break;
                        case 'via_options':
                            $rows = array();
                            if($meta) $rows = $meta;
                            $c = 0;
                            if ( count( $rows ) > 0 ) {
                                foreach( $rows as $row ) {
                                    if ( isset( $row['c_label'] ) || isset( $row['url'] ) ) {
                                        echo '
                                        <p class="opt-via-row jl_cus_repeater" style="margin-bottom:10px;">
                                        <label for="'.$field['id'].'['.$c.'][c_label]">Label :</label>
                                        <input type="text" name="'.$field['id'].'['.$c.'][c_label]" value="'.$row['c_label'].'" />
                                        <label for="'.$field['id'].'['.$c.'][url]">URL :</label>
                                        <input type="text" name="'.$field['id'].'['.$c.'][url]" value="'.$row['url'].'" />
                                        <a class="opt-remove-via button-secondary">Remove</a>
                                        </p>';
                                        $c = $c + 1;
                                    }
                                }
                            }
                            echo '<span id="opt-via-placeholder"></span>';
                            echo '<a class="add-opt-via button-primary" href="#">Add Post Via</a>';
                            echo '<br /><span style="margin-top: 0px; display: block;" class="description">'.$field['desc'].'</span>';
                            ?>
                            <script>
                                var $ = jQuery.noConflict();
                                $(document).ready(function() {
                                    var count_via = <?php echo esc_attr($c); ?>;
                                    $('.add-opt-via').click(function() {
                                        count_via = count_via + 1;
                                        $('#opt-via-placeholder').append('<p class="opt-via-row jl_cus_repeater" style="margin-bottom:10px;"><label for="<?php echo esc_attr($field['id']); ?>['+count_via+'][c_label]">Label : </label><input type="text" name="<?php echo esc_attr($field['id']); ?>['+count_via+'][c_label]" value="" /><label for="<?php echo esc_attr($field['id']); ?>['+count_via+'][url]"> URL : </label><input type="text" name="<?php echo esc_attr($field['id']); ?>['+count_via+'][url]" value="" /> <a class="opt-remove-via button-secondary">Remove</a></p>');
                                        return false;
                                    });

                                    $('body').on('click', '.opt-remove-via', function(){
                                        $(this).parent('.opt-via-row').remove();
                                    });

                                });
                            </script>
                            <?php
                        break;

					}
					echo '</div>';
				echo '</div>';

			}

			echo '</div>';
		}


		// Save data from metabox
		function save( $post_id)  {
			// verify nonce
			if ( ! isset( $_POST['wp_meta_box_nonce'] ) || !wp_verify_nonce( $_POST['wp_meta_box_nonce'], basename(__FILE__) ) ) {
				return $post_id;
			}

			// check autosave
			if (defined('DOING_AUTOSAVE') && DOING_AUTOSAVE)
				return $post_id;

			// check permissions
			if ('page' == $_POST['post_type']) {
				if (!current_user_can('edit_page', $post_id))
					return $post_id;
				} elseif (!current_user_can('edit_post', $post_id)) {
					return $post_id;
			}

			// loop through fields and save the data
			foreach ( $this->_metabox['fields'] as $field ) {

				$old = get_post_meta($post_id, $field['id'], true);

				$new = isset( $_POST[$field['id']] ) ? $_POST[$field['id']] : null;

				if ($new && $new != $old) {
					update_post_meta($post_id, $field['id'], $new);
				}
				elseif ('' == $new && $old) {
					delete_post_meta($post_id, $field['id'], $old);
				}

			} // end foreach
		}
	}



/*	Initialize Metabox
 *	--------------------------------------------------------- */
	function bopea_init_metaboxes() {
		if ( class_exists( 'bopea_Meta_Box' ) ) {



//// user metabox field
add_filter( 'bopea_meta_metaboxes', 'bopea_meta_metaboxes' );

function bopea_meta_metaboxes( array $metaboxes ) {

	$option_sidebar = array();
	$sidebars = get_option('sbg_sidebars');
	$option_sidebar['default']= esc_html__( 'Default Sidebar', 'bopea-function' );
	if(isset($sidebars)) {
		if(is_array($sidebars)) {
			foreach($sidebars as $sidebar) {
				$sidebar_lower = strtolower($sidebar);
				$sidebarid = str_replace(' ','-', $sidebar_lower);
				$option_sidebar[$sidebarid] = $sidebar;
			}
		}
	}

	//Header
	$args = array(
		'post_type'     => 'jl_layout',
		'post_status'   => array( 'publish' ),
		'numberposts'   => -1,
		'orderby'       => 'title',
		'order'         => 'ASC',
		'suppress_filters'   => false
   );
   $layouts = get_posts($args);
   $jl_layouts = array();
   $jl_layouts['']= esc_html__( 'Default Layout', 'bopea-function' );
   
   if(!empty($layouts)){
	   foreach ($layouts as $layout){
		   $jl_layouts[$layout->ID] = $layout->post_title;
	   }
   }

   //menu
   $menus = get_terms('nav_menu');
   $menus_select = array(
		'' => 'Default Menu'
	);
	foreach($menus as $each_menu){
		$menus_select[$each_menu->slug] = $each_menu->name;
	}



		$metaboxes[] = array(
			'id'		 => 'jl_single_post_layouts',
			'title'      => esc_html__('Single Post Options', 'bopea-function'),
			'pages'      => array('post'), // Post type
			'context'    => 'normal',
			'priority'   => 'high',
			'fields' => array(

				// tab open
                array(
					'label' => "",
					'id'	=> 'options-group-1',
					'type'	=> 'topen'
				),
                // tab open                			

				array(
					'label' => esc_html__('Disable left post share', 'bopea-function'),		
					'desc'	=> esc_html__('Enable or disable left post share', 'bopea-function'),			
					'id'	=> 'disable_post_share',
					'type'	=> 'checkbox'
				),

				array(
					'label' => esc_html__('Post Subtitle', 'bopea-function'),
					'id'	=> 'single_post_subtitle',
					'type'	=> 'text'
				),
				array(
					'label' => esc_html__('Select post layout', 'bopea-function'),
					'desc'	=> '',
					'id'	=> 'single_post_layout',
					'std' => '',
					'type'	=> 'select',
					'options' => array (
						'' => esc_html__('Use Customizer Setting', 'bopea-function'),
						'single1' => esc_html__('Post Layout 1', 'bopea-function'),
						'single2' => esc_html__('Post Layout 2', 'bopea-function'),
						'single3' => esc_html__('Post Layout 3', 'bopea-function'),
						'single4' => esc_html__('Post Layout 4', 'bopea-function'),
						'single5' => esc_html__('Post Layout 5', 'bopea-function'),
						'single6' => esc_html__('Post Layout 6', 'bopea-function'),
						'single7' => esc_html__('Post Layout 7', 'bopea-function'),
						'single8' => esc_html__('Post Layout 8', 'bopea-function'),
						'single9' => esc_html__('Post Layout 9', 'bopea-function'),
						'single10' => esc_html__('Post Layout 10', 'bopea-function'),
						'single11' => esc_html__('Post Layout 11', 'bopea-function'),
						'single12' => esc_html__('Post Layout 12', 'bopea-function'),
						'single13' => esc_html__('Post Layout 13', 'bopea-function'),
						'single14' => esc_html__('Post Layout 14', 'bopea-function'),						
						)
				),
				array(
					'label' => esc_html__('Post sidebar', 'bopea-function'),
					'desc'	=> '',
					'id'	=> 'single_post_sidebar',
					'std' => '',
					'type'	=> 'select',
					'options' => $option_sidebar
				),

				array(
					'label' => esc_html__('Single Full-Width options', 'bopea-function'),
					'desc'	=> '',
					'id'	=> 'sg_post_opt_full',
					'std' => '',
					'type'	=> 'select',
					'options' => array (
						'' => esc_html__('Use Customizer Setting', 'bopea-function'),
						'jl_sg_side' => esc_html__('Single post with sidebar', 'bopea-function'),
						'jl_sg_full' => esc_html__('Single post full width', 'bopea-function')
					)
				),

				array(
					'label' => esc_html__('Sidebar Position', 'bopea-function'),
					'desc'	=> '',
					'id'	=> 'post_sidebar_position',
					'std' => '',
					'type'	=> 'select',
					'options' => array (
						'' => esc_html__('Use Customizer Setting', 'bopea-function'),
						'jl_sleft_side' => esc_html__('Left Sidebar', 'bopea-function'),
						'jl_sright_side' => esc_html__('Right Sidebar', 'bopea-function')
						)
				),

				array(
					'label' => esc_html__('Auto load next post', 'bopea-function'),
					'desc'	=> '',
					'id'	=> 'single_auto_load_post',
					'std' => '',
					'type'	=> 'select',
					'options' => array (
						'' => esc_html__('Use Customizer Setting', 'bopea-function'),
						'enable' => esc_html__('Enable', 'bopea-function'),
						'disable' => esc_html__('Disable', 'bopea-function')
						)
				),

				array(
					'label' => esc_html__('Select Custom Header Layout', 'bopea-function'),
					'desc'	=> esc_html__('Choose layout to overwrite default header', 'bopea-function'),
					'id'	=> 'custom_header_layout',
					'std' => '',
					'type'	=> 'select',
					'options' => $jl_layouts
				),

				array(
					'label' => esc_html__('Select Custom Header Layout Sticky', 'bopea-function'),
					'desc'	=> esc_html__('Choose layout to overwrite default sticky header: Note this options work when you choose (Layout Header)', 'bopea-function'),
					'id'	=> 'custom_header_sticky',
					'std' => '',
					'type'	=> 'select',
					'options' => $jl_layouts
				),

				array(
					'label' => esc_html__('Select Mobile Menu', 'bopea-function'),
					'desc'	=> esc_html__('Choose menu to overwrite default mobile menu', 'bopea-function'),
					'id'	=> 'custom_mobile_menu',
					'std' => '',
					'type'	=> 'select',
					'options' => $menus_select
				),

				array(
					'label' => esc_html__('Select Custom Footer Layout', 'bopea-function'),
					'desc'	=> esc_html__('Choose layout to overwrite default footer', 'bopea-function'),
					'id'	=> 'custom_footer_layout',
					'std' => '',
					'type'	=> 'select',
					'options' => $jl_layouts
				),

                // tab close
				array(
					'label' => "",
					'id'	=> 'post_option_close',
					'type'	=> 'tclose'
				),
				// tab close

				// tab open
                array(
					'label' => "",
					'id'	=> 'options-group-2',
					'type'	=> 'topen'
				),
                // tab open

                array(
                    'label' => esc_html__('Enable Review', 'nanopress'),
                    'desc'  => esc_html__('Enable or disable review', 'bopea-function'),
                    'id'    => 'single_post_review',
                    'type'  => 'checkbox'
                ),
                array(
                    'label' => esc_html__('Rating Criteria', 'bopea-function'),
                    'desc'  => esc_html__('Label : A name of criteria - Score : A number value between 0 - 10, incerement 0.1', 'bopea-function'),
                    'id'    => 'rating_criteria',
                    'type'  => 'rating_criteria'
                ),
				array(
                    'label' => esc_html__('Custom total value', 'bopea-function'),
					'desc'  => esc_html__('Display custom total value with number only (EX:0.1 - 10)', 'bopea-function'),
                    'id'    => 'review_cus_total',
                    'type'  => 'text',
                    'std'   => ''
                ),
                array(
                    'label' => esc_html__('Hide/Show Review bar', 'bopea-function'),
                    'id'    => 'jl_review_bar',
                    'std' => '',
					'type'	=> 'select',
					'options' => array (
						'' => esc_html__('Use Customizer Setting', 'bopea-function'),
						'show' => esc_html__('show', 'bopea-function'),
						'hide' => esc_html__('hide', 'bopea-function')						
					)
                ),
				array(
                    'label' => esc_html__('Rating Type', 'bopea-function'),
                    'id'    => 'rating_type',
                    'type'  => 'select',
                    'options' => array ( 
						'star' => esc_html__('Star', 'bopea-function'),
						'number' => esc_html__('Number', 'bopea-function'), 
						'letter' => esc_html__('Letter Grade', 'bopea-function'), 
						'percent' => esc_html__('Percentage', 'bopea-function')
					)
                ),
                array(
						'label' => esc_html__('Review Image', 'bopea-function'),
						'desc'	=> "",
						'id'	=> 'review_image',
						'type'	=> 'image',
						'std'	=> ''
					),
                array(
                    'label' => esc_html__('Review color', 'bopea-function'),
                    'id'    => 'review_color',
                    'type'  => 'color',
                    'std'   => ''
                ),
                array(
                    'label' => esc_html__('Review Title', 'bopea-function'),
                    'id'    => 'review_box_title',
                    'type'  => 'text',
                    'std'   => 'Review Overview'
                ),
                array(
                    'label' => esc_html__('Summary', 'bopea-function'),
                    'desc'  => esc_html__('Summary in review box', 'bopea-function'),
                    'id'    => 'review_summary',
                    'type'  => 'textarea',
                    'std'   => ''
                ),
                array(
                    'label' => esc_html__('Positives', 'bopea-function'),
                    'desc'  => esc_html__('Positives review each line in review box.', 'bopea-function'),
                    'id'    => 'review_pos',
                    'type'  => 'textarea',
                    'std'   => ''
                ),
                array(
                    'label' => esc_html__('Negatives', 'bopea-function'),
                    'desc'  => esc_html__('Negatives review each line in review box', 'bopea-function'),
                    'id'    => 'review_neg',
                    'type'  => 'textarea',
                    'std'   => ''
                ),

                array(
                    'label' => esc_html__('Review Button Label', 'bopea-function'),
                    'id'    => 'review_btn_label',
                    'type'  => 'text',
                    'std'   => ''
                ),

                array(
                    'label' => esc_html__('Review Button URL', 'bopea-function'),
                    'id'    => 'review_btn_url',
                    'type'  => 'text',
                    'std'   => ''
                ),

                // tab close
				array(
					'label' => "",
					'id'	=> 'review_close',
					'type'	=> 'tclose'
				),
				// tab close



				// tab open
                array(
					'label' => "",
					'id'	=> 'options-group-3',
					'type'	=> 'topen'
				),
                // tab open

                array(
					'label' => esc_html__('Gallery type', 'bopea-function'),
					'desc'	=> '',
					'id'	=> 'jl_gallery_type',
					'std' => '',
					'type'	=> 'select',
					'options' => array (
						'' => esc_html__('Use Customizer Setting', 'bopea-function'),
						'slider' => esc_html__('Slider', 'bopea-function'),
						'popup' => esc_html__('Popup', 'bopea-function')
						)
				),

                // gallery
				array(
					'label' => esc_html__('gallery', 'bopea-function'),
					'id'	=> 'gallery_post_format',
					'type'	=> 'gallery'
				),

				// tab close
				array(
					'label' => "",
					'id'	=> 'post_gallery_close',
					'type'	=> 'tclose'
				),
				// tab close

				// tab open
                array(
					'label' => "",
					'id'	=> 'options-group-4',
					'type'	=> 'topen'
				),
                // tab open

				// quote
				array(
					'label' => esc_html__('Quote title', 'bopea-function'),
					'id'	=> 'quote_post_title',
					'type'	=> 'textarea'
				),
				array(
					'label' => esc_html__('Quote author', 'bopea-function'),
					'id'	=> 'quote_post_author',
					'type'	=> 'text'
				),

				// tab close
				array(
					'label' => "",
					'id'	=> 'post_quote_close',
					'type'	=> 'tclose'
				),
				// tab close

				// tab open
                array(
					'label' => "",
					'id'	=> 'options-group-5',
					'type'	=> 'topen'
				),
                // tab open

				array(
					'label' => esc_html__('Video Type', 'bopea-function'),
					'desc'	=> '',
					'id'	=> 'jl_vid_type',
					'std' => 'video_post_embed',
					'type'	=> 'select',
					'options' => array (
						'video_post_embed' => esc_html__('Video embed', 'bopea-function'),
						'video_local' => esc_html__('Video HTML5 MP4', 'bopea-function'),
						)
				),
				array(
					'label' => esc_html__('Archive post video style', 'bopea-function'),
					'desc'	=> '',
					'id'	=> 'jl_video_style',
					'std' => '',
					'type'	=> 'select',
					'options' => array (
						'' => esc_html__('Use Customizer Setting', 'bopea-function'),
						'background' => esc_html__('Background video', 'bopea-function'),
						'popup' => esc_html__('Popup', 'bopea-function')
						)
				),
				array(
					'label' => esc_html__('Single overlay layout video style', 'bopea-function'),
					'desc'	=> '',
					'id'	=> 'jl_sg_video_style',
					'std' => '',
					'type'	=> 'select',
					'options' => array (
						'' => esc_html__('Use Customizer Setting', 'bopea-function'),
						'background' => esc_html__('Background video', 'bopea-function'),
						'popup' => esc_html__('Popup', 'bopea-function')
						)
				),
				// video
				array(
					'label' => esc_html__('Video url', 'bopea-function'),
					'desc'  => esc_html__('Youtube video url, Vimeo video url, Dailymotion video url', 'bopea-function'),
					'id'	=> 'video_post_embed',
					'type'	=> 'textarea'
				),
				array(
						'label' => esc_html__('Video MP4', 'bopea-function'),
						'desc'	=> "",
						'id'	=> 'video_local',
						'type'	=> 'image',
						'std'	=> ''
					),

				// tab close
				array(
					'label' => "",
					'id'	=> 'post_video_close',
					'type'	=> 'tclose'
				),
				// tab close

				// tab open
                array(
					'label' => "",
					'id'	=> 'options-group-6',
					'type'	=> 'topen'
				),
                // tab open

				// audio
				array(
					'label' => esc_html__('Audio Type', 'bopea-function'),
					'desc'	=> '',
					'id'	=> 'jl_audio_type',
					'std' => 'audio_post_embed',
					'type'	=> 'select',
					'options' => array (
						'audio_post_embed' => esc_html__('Audio embed', 'bopea-function'),
						'audio_local' => esc_html__('Audio HTML5 MP3', 'bopea-function')
						)
				),
				array(
					'label' => esc_html__('Audio Embed', 'bopea-function'),
					'id'	=> 'audio_post_embed',
					'type'	=> 'textarea'
				),
				array(
						'label' => esc_html__('Audio MP3', 'bopea-function'),
						'desc'	=> "",
						'id'	=> 'audio_local',
						'type'	=> 'image',
						'std'	=> ''
				),

				// tab close
				array(
					'label' => "",
					'id'	=> 'post_audio_close',
					'type'	=> 'tclose'
				),
				// tab close

				// tab open
                array(
					'label' => "",
					'id'	=> 'options-group-7',
					'type'	=> 'topen'
				),
                // tab open

                array(
					'label' => esc_html__('Enable Sponsored Post', 'bopea-function'),
					'desc'	=> esc_html__('Enable or disable sponsored post', 'bopea-function'),
					'id'	=> 'enable_sponsored_post',
					'type'	=> 'checkbox'
				),

				array(
					'label' => esc_html__('Sponsor URL', 'bopea-function'),
					'id'	=> 'sponsored_post_url',
					'type'	=> 'text'
				),				
				array(
						'label' => esc_html__('Sponsor logo', 'bopea-function'),
						'desc'	=> "",
						'id'	=> 'sponsored_logo',
						'type'	=> 'image',
						'std'	=> ''
				),


				// tab close
				array(
					'label' => "",
					'id'	=> 'post_sponsor_close',
					'type'	=> 'tclose'
				),
				// tab close


				// tab open
                array(
					'label' => "",
					'id'	=> 'options-group-8',
					'type'	=> 'topen'
				),
                // tab open

                array(
                    'label' => esc_html__('Post Sources', 'bopea-function'),
                    'id'    => 'source_options',
                    'type'  => 'source_options'
                ),

                array(
                    'label' => esc_html__('Post Via', 'bopea-function'),
                    'id'    => 'via_options',
                    'type'  => 'via_options'
                ),



				// tab close
				array(
					'label' => "",
					'id'	=> 'post_source_via_close',
					'type'	=> 'tclose'
				),
				// tab close



			)
		);


$metaboxes[] = array(
			'id'		 => 'jl_option_page',
			'title'      => esc_html__('Page options', 'bopea-function'),
			'pages'      => array('page'), // Post type
			'context'    => 'normal',
			'priority'   => 'high',
			'fields' => array(

				// tab open
                array(
					'label' => "",
					'id'	=> 'options-group-1',
					'type'	=> 'topen'
				),
                // tab open							

				array(
					'label' => esc_html__('Website layout (boxed/full)', 'bopea-function'),
					'desc'	=> '',
					'id'	=> 'jl_site_layout',
					'std' => '',
					'type'	=> 'select',
					'options' => array (
						'' => esc_html__('Use Customizer Setting', 'bopea-function'),
						'jl_lfull' => esc_html__('Full width', 'bopea-function'),
						'jl_lbox' => esc_html__('Boxed width', 'bopea-function'),									
						)
				),
				array(
					'label' => esc_html__('Enable header overlay', 'bopea-function'),
					'desc'	=> esc_html__('Enable or disable header overlay', 'bopea-function'),
					'id'	=> 'jl_header_tp',
					'type'	=> 'checkbox'
				),	
				array(
					'label' => esc_html__('Disable featured image', 'bopea-function'),
					'desc'	=> esc_html__('Enable or disable featured image', 'bopea-function'),
					'id'	=> 'jl_hide_featured',
					'type'	=> 'checkbox'
				),
				
				array(
					'label' => esc_html__('Disable page breadcrumbs', 'bopea-function'),
					'desc'	=> esc_html__('Enable or disable page breadcrumbs', 'bopea-function'),
					'id'	=> 'jl_hide_page_breadcrumb',
					'type'	=> 'checkbox'
				),

				array(
					'label' => esc_html__('Disable page title', 'bopea-function'),
					'desc'	=> esc_html__('Enable or disable page title', 'bopea-function'),
					'id'	=> 'jl_hide_page_title',
					'type'	=> 'checkbox'
				),

				array(
					'label' => esc_html__('Page Subtitle', 'bopea-function'),
					'id'	=> 'single_page_subtitle',
					'type'	=> 'text'
				),

				array(
					'label' => esc_html__('Page sidebar', 'bopea-function'),
					'desc'	=> '',
					'id'	=> 'single_page_sidebar',
					'std' => '',
					'type'	=> 'select',
					'options' => $option_sidebar
				),

				array(
					'label' => esc_html__('Select Custom Header Layout', 'bopea-function'),
					'desc'	=> esc_html__('Choose layout to overwrite default header', 'bopea-function'),
					'id'	=> 'custom_header_layout',
					'std' => '',
					'type'	=> 'select',
					'options' => $jl_layouts
				),

				array(
					'label' => esc_html__('Select Custom Header Layout Sticky', 'bopea-function'),
					'desc'	=> esc_html__('Choose layout to overwrite default sticky header: Note this options work when you choose (Layout Header)', 'bopea-function'),
					'id'	=> 'custom_header_sticky',
					'std' => '',
					'type'	=> 'select',
					'options' => $jl_layouts
				),

				array(
					'label' => esc_html__('Select Mobile Menu', 'bopea-function'),
					'desc'	=> esc_html__('Choose menu to overwrite default mobile menu', 'bopea-function'),
					'id'	=> 'custom_mobile_menu',
					'std' => '',
					'type'	=> 'select',
					'options' => $menus_select
				),

				array(
					'label' => esc_html__('Select Custom Footer Layout', 'bopea-function'),
					'desc'	=> esc_html__('Choose layout to overwrite default footer', 'bopea-function'),
					'id'	=> 'custom_footer_layout',
					'std' => '',
					'type'	=> 'select',
					'options' => $jl_layouts
				),

				// tab close
				array(
					'label' => "",
					'id'	=> 'post_options_close',
					'type'	=> 'tclose'
				),
				// tab close

			)
		);

		$metaboxes[] = array(
			'id'		 => 'jl_option_layout',
			'title'      => esc_html__('Layout options', 'bopea-function'),
			'pages'      => array('jl_layout'),
			'context'    => 'normal',
			'priority'   => 'high',
			'fields' => array(

				array(
					'label' => esc_html__('Prevent flickers layout', 'bopea-function'),
					'desc'	=> esc_html__('Enable or disable option to render CSS on header for layout in (Widget, Post content)', 'bopea-function'),
					'id'	=> 'jl_erender',
					'type'	=> 'checkbox'
				),

			)
		);

		$metaboxes[] = array(
			'id'		 => 'jl_option_layout',
			'title'      => esc_html__('Ads options', 'bopea-function'),
			'pages'      => array('jl_ads'),
			'context'    => 'normal',
			'priority'   => 'high',
			'fields' => array(
				array(
                    'label' => esc_html__('Ads script', 'bopea-function'),
                    'desc'  => esc_html__('Add your ads script here', 'bopea-function'),
                    'id'    => 'cus_ads_script',
                    'type'  => 'textarea',
                    'std'   => ''
                ),
				array(
					'label' => esc_html__('Ads Size Desktop', 'bopea-function'),
					'desc'	=> '',
					'id'	=> 'jl_ads_dk',
					'std' => '17',
					'type'	=> 'select',
					'options' => array (
						'1' => esc_html__('Leaderboard (728x90)', 'bopea-function'),
						'2' => esc_html__('Banner (468x60)', 'bopea-function'),
						'3' => esc_html__('Half banner (234x60)', 'bopea-function'),
						'4' => esc_html__('Button (125x125)', 'bopea-function'),
						'5' => esc_html__('Skyscraper (120x600)', 'bopea-function'),
						'6' => esc_html__('Wide Skyscraper (160x600)', 'bopea-function'),
						'7' => esc_html__('Small Rectangle (180x150)', 'bopea-function'),
						'8' => esc_html__('Vertical Banner (120 x 240)', 'bopea-function'),
						'9' => esc_html__('Small Square (200x200)', 'bopea-function'),
						'10' => esc_html__('Square (250x250)', 'bopea-function'),
						'11' => esc_html__('Medium Rectangle (300x250)', 'bopea-function'),
						'12' => esc_html__('Large Rectangle (336x280)', 'bopea-function'),
						'13' => esc_html__('Half Page (300x600)', 'bopea-function'),
						'14' => esc_html__('Portrait (300x1050)', 'bopea-function'),
						'15' => esc_html__('Mobile Banner (320x50)', 'bopea-function'),
						'16' => esc_html__('Large Leaderboard (970x90)', 'bopea-function'),
						'17' => esc_html__('Billboard (970x250)', 'bopea-function'),
						)
				),
				array(
					'label' => esc_html__('Ads Size tablet', 'bopea-function'),
					'desc'	=> '',
					'id'	=> 'jl_ads_tb',
					'std' => '1',
					'type'	=> 'select',
					'options' => array (
						'1' => esc_html__('Leaderboard (728x90)', 'bopea-function'),
						'2' => esc_html__('Banner (468x60)', 'bopea-function'),
						'3' => esc_html__('Half banner (234x60)', 'bopea-function'),
						'4' => esc_html__('Button (125x125)', 'bopea-function'),
						'5' => esc_html__('Skyscraper (120x600)', 'bopea-function'),
						'6' => esc_html__('Wide Skyscraper (160x600)', 'bopea-function'),
						'7' => esc_html__('Small Rectangle (180x150)', 'bopea-function'),
						'8' => esc_html__('Vertical Banner (120 x 240)', 'bopea-function'),
						'9' => esc_html__('Small Square (200x200)', 'bopea-function'),
						'10' => esc_html__('Square (250x250)', 'bopea-function'),
						'11' => esc_html__('Medium Rectangle (300x250)', 'bopea-function'),
						'12' => esc_html__('Large Rectangle (336x280)', 'bopea-function'),
						'13' => esc_html__('Half Page (300x600)', 'bopea-function'),
						'14' => esc_html__('Portrait (300x1050)', 'bopea-function'),
						'15' => esc_html__('Mobile Banner (320x50)', 'bopea-function'),
						'16' => esc_html__('Large Leaderboard (970x90)', 'bopea-function'),
						'17' => esc_html__('Billboard (970x250)', 'bopea-function'),
						)
				),
				array(
					'label' => esc_html__('Ads Size Mobile', 'bopea-function'),
					'desc'	=> '',
					'id'	=> 'jl_ads_mb',
					'std' => '11',
					'type'	=> 'select',
					'options' => array (
						'1' => esc_html__('Leaderboard (728x90)', 'bopea-function'),
						'2' => esc_html__('Banner (468x60)', 'bopea-function'),
						'3' => esc_html__('Half banner (234x60)', 'bopea-function'),
						'4' => esc_html__('Button (125x125)', 'bopea-function'),
						'5' => esc_html__('Skyscraper (120x600)', 'bopea-function'),
						'6' => esc_html__('Wide Skyscraper (160x600)', 'bopea-function'),
						'7' => esc_html__('Small Rectangle (180x150)', 'bopea-function'),
						'8' => esc_html__('Vertical Banner (120 x 240)', 'bopea-function'),
						'9' => esc_html__('Small Square (200x200)', 'bopea-function'),
						'10' => esc_html__('Square (250x250)', 'bopea-function'),
						'11' => esc_html__('Medium Rectangle (300x250)', 'bopea-function'),
						'12' => esc_html__('Large Rectangle (336x280)', 'bopea-function'),
						'13' => esc_html__('Half Page (300x600)', 'bopea-function'),
						'14' => esc_html__('Portrait (300x1050)', 'bopea-function'),
						'15' => esc_html__('Mobile Banner (320x50)', 'bopea-function'),
						'16' => esc_html__('Large Leaderboard (970x90)', 'bopea-function'),
						'17' => esc_html__('Billboard (970x250)', 'bopea-function'),
						)
				),
			)
		);


	return $metaboxes;
}
			$metaboxes = array();
			$metaboxes = apply_filters ( 'bopea_meta_metaboxes' , $metaboxes );
			foreach ( $metaboxes as $metabox ) {
				$my_box = new bopea_Meta_Box( $metabox );
			}
		}
	}
add_action( 'init', 'bopea_init_metaboxes', 9999 );


Current_dir [ WRITEABLE ] Document_root [ WRITEABLE ]


[ Back ]
NAME
SIZE
LAST TOUCH
USER
CAN-I?
FUNCTIONS
..
--
25 Nov 2025 10.53 AM
bravrvjk / bravrvjk
0755
bbpress
--
25 Nov 2025 10.53 AM
bravrvjk / bravrvjk
0755
function
--
25 Nov 2025 10.53 AM
bravrvjk / bravrvjk
0755
woocommerce
--
25 Nov 2025 10.53 AM
bravrvjk / bravrvjk
0755
cb.php
42.693 KB
25 Nov 2025 10.53 AM
bravrvjk / bravrvjk
0644
core.php
73.26 KB
25 Nov 2025 10.53 AM
bravrvjk / bravrvjk
0644
date-time.php
6.077 KB
25 Nov 2025 10.53 AM
bravrvjk / bravrvjk
0644
file.php
1.207 KB
25 Nov 2025 10.53 AM
bravrvjk / bravrvjk
0644
fonts-tax.php
3.68 KB
25 Nov 2025 10.53 AM
bravrvjk / bravrvjk
0644
fonts.php
17.657 KB
25 Nov 2025 10.53 AM
bravrvjk / bravrvjk
0644
header-footer.php
6.572 KB
25 Nov 2025 10.53 AM
bravrvjk / bravrvjk
0644
metas.php
12.807 KB
25 Nov 2025 10.53 AM
bravrvjk / bravrvjk
0644
sb.php
9.413 KB
25 Nov 2025 10.53 AM
bravrvjk / bravrvjk
0644
single-content.php
1.979 KB
25 Nov 2025 10.53 AM
bravrvjk / bravrvjk
0644

GRAYBYTE WORDPRESS FILE MANAGER @ 2025 CONTACT ME
Static GIF