You are here

function quicktabs_quicktabs_tabstyles in Quick Tabs 7.2

Same name and namespace in other branches
  1. 5 quicktabs.module \quicktabs_quicktabs_tabstyles()
  2. 6.3 quicktabs.module \quicktabs_quicktabs_tabstyles()
  3. 6 quicktabs.module \quicktabs_quicktabs_tabstyles()
  4. 6.2 quicktabs.module \quicktabs_quicktabs_tabstyles()

Implements hook_quicktabs_tabstyles().

This hook allows other modules to create additional tab styles for the quicktabs module.

Return value

array An array of key => value pairs suitable for inclusion as the #options in a select or radios form element. Each key must be the location of a css file for a quick tabs style. Each value should be the name of the style.

File

./quicktabs.module, line 559

Code

function quicktabs_quicktabs_tabstyles() {
  $tabstyles_directory = drupal_get_path('module', 'quicktabs') . '/tabstyles';
  $files = file_scan_directory($tabstyles_directory, '/\\.css$/');
  $tabstyles = array();
  foreach ($files as $file) {

    // Skip RTL files.
    if (!strpos($file->name, '-rtl')) {
      $tabstyles[$file->uri] = drupal_ucfirst($file->name);
    }
  }
  return $tabstyles;
}