'bi '.$match[1], 'label' => $match[1]); } //Flaticon $et_matches = get_et_icons(); foreach($et_matches as $match) { $icons[] = array('value' => 'icon '.$match[1], 'label' => $match[1]); } $icons = array_column($icons, 'label', 'value'); //print_r($icons); exit('hellow'); return $icons; } //Icomoon Icons function get_et_icons() { $pattern = '/\.(icon-(?:\w+(?:-)?)+):before\s*{\s*content/'; $subject = file_get_contents(get_template_directory() . '/assets/vendors/thm-icons/style.css'); preg_match_all($pattern, $subject, $matches, PREG_SET_ORDER); return $matches; } //get blog categories function get_blog_categories() { $options = array(); $taxonomy = 'category'; if (!empty($taxonomy)) { $terms = get_terms( array( 'parent' => 0, 'taxonomy' => $taxonomy, 'hide_empty' => false, ) ); if (!empty($terms)) { foreach ($terms as $term) { if (isset($term)) { $options[''] = 'Select'; if (isset($term->slug) && isset($term->name)) { $options[$term->slug] = $term->name; } } } } } return $options; } //get Project categories function get_project_categories() { $options = array(); $taxonomy = 'project_cat'; if (!empty($taxonomy)) { $terms = get_terms( array( 'parent' => 0, 'taxonomy' => $taxonomy, 'hide_empty' => false, ) ); if (!empty($terms)) { foreach ($terms as $term) { if (isset($term)) { $options[''] = 'Select'; if (isset($term->slug) && isset($term->name)) { $options[$term->slug] = $term->name; } } } } } return $options; } //get Testimonials categories function get_testimonials_categories() { $options = array(); $taxonomy = 'testimonials_cat'; if (!empty($taxonomy)) { $terms = get_terms( array( 'parent' => 0, 'taxonomy' => $taxonomy, 'hide_empty' => false, ) ); if (!empty($terms)) { foreach ($terms as $term) { if (isset($term)) { $options[''] = 'Select'; if (isset($term->slug) && isset($term->name)) { $options[$term->slug] = $term->name; } } } } } return $options; } //get Product categories function get_product_categories() { $options = array(); $taxonomy = 'product_cat'; if (!empty($taxonomy)) { $terms = get_terms( array( 'parent' => 0, 'taxonomy' => $taxonomy, 'hide_empty' => false, ) ); if (!empty($terms)) { foreach ($terms as $term) { if (isset($term)) { $options[''] = 'Select'; if (isset($term->slug) && isset($term->name)) { $options[$term->slug] = $term->name; } } } } } return $options; } //get Team categories function get_team_categories() { $options = array(); $taxonomy = 'team_cat'; if (!empty($taxonomy)) { $terms = get_terms( array( 'parent' => 0, 'taxonomy' => $taxonomy, 'hide_empty' => false, ) ); if (!empty($terms)) { foreach ($terms as $term) { if (isset($term)) { $options[''] = 'Select'; if (isset($term->slug) && isset($term->name)) { $options[$term->slug] = $term->name; } } } } } return $options; } function thinkai_the_pagination2($args = array(), $echo = 1) { global $wp_query; $default = array('base' => str_replace( 99999, '%#%', esc_url( get_pagenum_link( 99999 ) ) ), 'format' => '?paged=%#%', 'current' => max( 1, get_query_var('paged') ), 'total' => $wp_query->max_num_pages, 'next_text' => '»', 'prev_text' => '«', 'type'=>'list','add_args' => false); $args = wp_parse_args($args, $default); $pagination = str_replace("