You are here

function eu_cookie_compliance_menu in EU Cookie Compliance (GDPR Compliance) 7

Same name and namespace in other branches
  1. 5 eu_cookie_compliance.module \eu_cookie_compliance_menu()
  2. 6 eu_cookie_compliance.module \eu_cookie_compliance_menu()
  3. 7.2 eu_cookie_compliance.module \eu_cookie_compliance_menu()

Implements hook_menu().

File

./eu_cookie_compliance.module, line 16
EU cookie compliance primary module file.

Code

function eu_cookie_compliance_menu() {
  $items['admin/config/system/eu-cookie-compliance'] = array(
    'title' => 'EU Cookie Compliance',
    'description' => 'Make your web site compliant with the EU Directive on Privacy and Electronic Communications.',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'eu_cookie_compliance_admin_form',
    ),
    'access arguments' => array(
      'administer EU Cookie Compliance popup',
    ),
    'file' => 'eu_cookie_compliance.admin.inc',
  );
  $items['admin/config/system/eu-cookie-compliance/settings'] = array(
    'title' => 'Settings',
    'description' => 'Configure the cookie consent popup.',
    'weight' => 0,
    'type' => MENU_DEFAULT_LOCAL_TASK,
  );
  $items['admin/config/system/eu-cookie-compliance/categories'] = array(
    'title' => 'Categories',
    'description' => 'Administer cookie categories.',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'eu_cookie_compliance_admin_categories_form',
    ),
    'access arguments' => array(
      'administer EU Cookie Compliance categories',
    ),
    'file' => 'eu_cookie_compliance.admin.categories.inc',
    'weight' => 1,
    'type' => MENU_LOCAL_TASK,
  );
  $items['admin/config/system/eu-cookie-compliance/categories/add'] = array(
    'title' => 'Add new category',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'eu_cookie_compliance_admin_category_form',
    ),
    'access arguments' => array(
      'administer EU Cookie Compliance categories',
    ),
    'file' => 'eu_cookie_compliance.admin.categories.inc',
  );
  $items['admin/config/system/eu-cookie-compliance/categories/%/edit'] = array(
    'title' => 'Edit',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'eu_cookie_compliance_admin_category_form',
      5,
    ),
    'access arguments' => array(
      'administer EU Cookie Compliance categories',
    ),
    'file' => 'eu_cookie_compliance.admin.categories.inc',
  );
  $items['admin/config/system/eu-cookie-compliance/categories/%/delete'] = array(
    'title' => 'Delete',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'eu_cookie_compliance_admin_category_delete_form',
      5,
    ),
    'access arguments' => array(
      'administer EU Cookie Compliance categories',
    ),
    'file' => 'eu_cookie_compliance.admin.categories.inc',
  );
  $items['eu-cookie-compliance/store_consent/%'] = array(
    'title' => 'EU Cookie Compliance store consent',
    'page callback' => 'eu_cookie_compliance_store_consent',
    'page arguments' => array(
      2,
    ),
    'access arguments' => array(
      'display EU Cookie Compliance popup',
    ),
    'type' => MENU_CALLBACK,
  );
  if (module_exists('geoip') || module_exists('smart_ip') || extension_loaded('geoip')) {
    $items['eu-cookie-compliance-check'] = array(
      'title' => 'Check if visit is from EU',
      'page callback' => 'eu_cookie_compliance_json',
      'type' => MENU_CALLBACK,
      'access arguments' => array(
        'display EU Cookie Compliance popup',
      ),
    );
  }
  return $items;
}