PluginProbe
Filter Everything — WordPress & WooCommerce Filters / trunk
Filter Everything — WordPress & WooCommerce Filters vtrunk
1.9.6 1.9.5 1.9.4 1.9.3 1.9.2.2 1.9.2.1 trunk 1.2.1 1.2.3 1.2.4 1.2.5 1.3.0 1.3.1 1.3.2 1.4.1 1.4.4 1.4.5 1.4.8 1.4.9 1.5.0 1.5.1 1.6.0 1.6.1 1.6.2 1.6.3 All 51 releases
filter-everything / views / admin / options.php

options.php in Filter Everything — WordPress & WooCommerce Filters trunk, at views/admin/options.php

43 lines 1.7 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * @var \FilterEverything\Filter\TabInterface[] $tabs
4 */
5
6 if ( ! defined('ABSPATH') ) {
7 exit;
8 }
9
10 ?>
11 <div class="wrap">
12 <h1><?php esc_html_e( 'Filters Settings', 'filter-everything' ) ?></h1>
13 <h2 class="nav-tab-wrapper">
14 <?php foreach ( $tabs as $tab ): ?>
15 <?php if ( $tab->valid() ): ?>
16 <?php
17 $class = ( $tab == $current ) ? ' nav-tab-active' : '';
18 $class .= ' wpc-tab-' . $tab->getName();
19 $tabUrl = admin_url( 'edit.php?post_type=filter-set&page=filters-settings&tab=' . $tab->getName() );
20 $label = esc_html($tab->getLabel());
21 ?>
22 <a class='nav-tab<?php echo esc_attr( $class ); ?>'
23 href='<?php echo esc_url( $tabUrl ); ?>'><?php echo $label ?>
24 <?php if (method_exists($tab, 'labelIcon')) {
25 echo '<span class="' . esc_attr('wpc-nav-tab-icon') . '">' .$tab->labelIcon() . '</span>';
26 }?>
27 </a>
28 <?php
29 if (method_exists($tab, 'getFreeLink')) {
30 $links = $tab->getFreeLink();
31 if (!empty($links)) {
32 $tabUrl = $links['link'];
33 $label = $links['text']; ?>
34 <a class='nav-tab<?php echo esc_attr(' wpc-tab-' . $tab->getName()); ?> wpc-pro-badge-text'
35 href='<?php echo esc_url($tabUrl); ?>'><?php echo $label ?></a>
36 <?php }
37 }
38 ?>
39 <?php endif; ?>
40 <?php endforeach; ?>
41 </h2>
42 <?php echo $current->render() //already escaped in the method ?>
43 </div>