eewee_options_page_tabs

The Eewee responsive design eewee options page tabs function.

Description

eewee_options_page_tabs( (string) $current = 'welcome' ); 

Parameters (1)

0. $current — Optional. (string) => 'welcome'
The current.

Usage

  1. if ( !function_exists( 'eewee_options_page_tabs' ) ) { 
  2. require_once '/includes/admin/theme-admin.php'; 
  3.  
  4. // The current. 
  5. $current = 'welcome'; 
  6.  
  7. // NOTICE! Understand what this does before running. 
  8. $result = eewee_options_page_tabs($current); 
  9.  

Defined (1)

The function is defined in the following location(s).

/includes/admin/theme-admin.php  
  1. function eewee_options_page_tabs( $current = 'welcome' ) { 
  2.  
  3. // Get the current tab 
  4. if ( isset( $_GET['tab'] ) ) : 
  5. $current = $_GET['tab']; 
  6. else: 
  7. $current = 'welcome'; 
  8. endif; 
  9.  
  10. // Fetch all Tabs from theme-settings.php 
  11.  
  12. // Loop to create Tabs Navigation 
  13. $links = array(); 
  14. foreach( $tabs as $tab => $name ) : 
  15. if ( $tab == $current ) : 
  16. $links[] = "<a class=\"nav-tab nav-tab-active\" href=\"?page=themeeewee&tab=$tab\">$name</a>"; 
  17. else : 
  18. $links[] = "<a class=\"nav-tab\" href=\"?page=themeeewee&tab=$tab\">$name</a>"; 
  19. endif; 
  20. endforeach; 
  21.  
  22. // Display Tab Navigaiton 
  23. echo '<h2 id="zee_tabs_navi" class="nav-tab-wrapper">'; 
  24. foreach ( $links as $link ) : echo $link; endforeach; 
  25. echo '</h2>';