function profile_user_categories
profile_user_categories()
Implements hook_user_categories().
File
- modules/profile/profile.module, line 501
- Support for configurable user profiles.
Code
function profile_user_categories() { $result = db_query("SELECT DISTINCT(category) FROM {profile_field}"); $data = array(); foreach ($result as $category) { $data[] = array( 'name' => $category->category, 'title' => $category->category, 'weight' => 3, 'access callback' => 'profile_category_access', 'access arguments' => array(1, $category->category) ); } return $data; }
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/modules!profile!profile.module/function/profile_user_categories/7.x