Warning: file_get_contents(https://raw.githubusercontent.com/Den1xxx/Filemanager/master/languages/ru.json): Failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found in /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php on line 107

Warning: Cannot modify header information - headers already sent by (output started at /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php:1) in /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php on line 234

Warning: Cannot modify header information - headers already sent by (output started at /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php:1) in /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php on line 235

Warning: Cannot modify header information - headers already sent by (output started at /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php:1) in /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php on line 236

Warning: Cannot modify header information - headers already sent by (output started at /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php:1) in /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php on line 237

Warning: Cannot modify header information - headers already sent by (output started at /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php:1) in /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php on line 238

Warning: Cannot modify header information - headers already sent by (output started at /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php:1) in /home/zoomride2022/public_html/myzoomride.com/wp-includes/certificates/system.php on line 239
course_post_type; $labels = array( 'name' => _x( 'Course Language', 'taxonomy general name', 'edumall-addons' ), 'singular_name' => _x( 'Language', 'taxonomy singular name', 'edumall-addons' ), 'search_items' => esc_html__( 'Search Languages', 'edumall-addons' ), 'popular_items' => esc_html__( 'Popular Languages', 'edumall-addons' ), 'all_items' => esc_html__( 'All Languages', 'edumall-addons' ), 'parent_item' => null, 'parent_item_colon' => null, 'edit_item' => esc_html__( 'Edit Language', 'edumall-addons' ), 'update_item' => esc_html__( 'Update Language', 'edumall-addons' ), 'add_new_item' => esc_html__( 'Add New Language', 'edumall-addons' ), 'new_item_name' => esc_html__( 'New Language Name', 'edumall-addons' ), 'separate_items_with_commas' => esc_html__( 'Separate languages with commas', 'edumall-addons' ), 'add_or_remove_items' => esc_html__( 'Add or remove languages', 'edumall-addons' ), 'choose_from_most_used' => esc_html__( 'Choose from the most used languages', 'edumall-addons' ), 'not_found' => esc_html__( 'No languages found.', 'edumall-addons' ), 'menu_name' => esc_html__( 'Course Languages', 'edumall-addons' ), 'back_to_items' => esc_html__( 'Back to Languages', 'edumall-addons' ), ); $args = array( 'hierarchical' => false, 'labels' => $labels, 'show_ui' => true, 'show_admin_column' => true, 'update_count_callback' => '_update_post_term_count', 'query_var' => true, 'show_in_rest' => true, 'rewrite' => array( 'slug' => apply_filters( 'edumall_course_language_slug', 'course-language' ) ), ); register_taxonomy( self::TAXONOMY_LANGUAGE, $course_post_type, $args ); } public function register_menu() { $course_post_type = tutor()->course_post_type; add_submenu_page( Entry::instance()->get_menu_slug(), esc_html__( 'Languages', 'edumall-addons' ), esc_html__( 'Languages', 'edumall-addons' ), 'manage_tutor', 'edit-tags.php?taxonomy=course-language&post_type=' . $course_post_type, null, 2 ); } public function parent_menu_active( $parent_file ) { $taxonomy = tutor_utils()->avalue_dot( 'taxonomy', $_GET ); if ( $taxonomy === 'course-language' ) { return Entry::instance()->get_menu_slug(); } return $parent_file; } public function submenu_file_active( $submenu_file, $parent_file ) { $taxonomy = tutor_utils()->avalue_dot( 'taxonomy', $_GET ); $course_post_type = tutor()->course_post_type; if ( 'course-language' === $taxonomy ) { return 'edit-tags.php?taxonomy=course-language&post_type=' . $course_post_type; } return $submenu_file; } public function add_language_fields() { ?>
term_id, 'thumbnail_id', true ) ); if ( $thumbnail_id ) { $thumbnail = wp_get_attachment_thumb_url( $thumbnail_id ); } else { $thumbnail = edumall_addons_placeholder_img_src(); } $flag_id = absint( get_term_meta( $term->term_id, 'flag_id', true ) ); if ( $flag_id ) { $flag = wp_get_attachment_thumb_url( $flag_id ); } else { $flag = edumall_addons_placeholder_img_src(); } ?>
'; } if ( 'flag' === $column ) { $flag_id = get_term_meta( $id, 'flag_id', true ); if ( $flag_id ) { $flag = wp_get_attachment_thumb_url( $flag_id ); } else { $flag = edumall_addons_placeholder_img_src(); } // Prevent esc_url from breaking spaces in urls for image embeds. Ref: https://core.trac.wordpress.org/ticket/23605 . $flag = str_replace( ' ', '%20', $flag ); $columns .= '' . esc_attr__( 'Flag', 'edumall-addons' ) . ''; } if ( 'handle' === $column ) { $columns .= ''; } return $columns; } public function enqueue_scripts() { $screen = get_current_screen(); if ( $screen->id === 'edit-course-language' ) { wp_enqueue_media(); wp_enqueue_script( 'edumall-addons-media', EDUMALL_ADDONS_ASSETS_URI . '/admin/js/media-upload.js', [ 'jquery' ], null, true ); } } public function add_visibility_setting( $setting ) { $new_setting_fields = [ [ 'key' => 'enable_course_language', 'type' => 'toggle_switch', 'label' => __( 'Course Language', 'edumall-addons' ), 'label_title' => '', 'default' => 'on', 'desc' => __( 'Enable to show courses language section', 'edumall-addons' ), ], ]; $design_course_detail_fields = $setting['design']['blocks']['course-details']['fields']; foreach ( $design_course_detail_fields as $key => $field ) { if ( 'course_details_adjustments' === $field['key'] ) { $setting['design']['blocks']['course-details']['fields'][ $key ]['group_options'] = array_merge( $field['group_options'], $new_setting_fields ); break; } } return $setting; } public function course_frontend_builder( $post ) { $args = [ 'taxonomy' => self::TAXONOMY_LANGUAGE, 'hide_empty' => 0, 'orderby' => 'name', 'hierarchical' => 0, 'show_option_none' => '—', 'name' => 'course-language', ]; $terms = get_the_terms( get_the_ID(), self::TAXONOMY_LANGUAGE ); if ( ! empty( $terms ) && ! is_wp_error( $terms ) ) { $args ['selected'] = $terms[0]->term_id; } ?>
initialize();