function ctools_path_visibility_ctools_access_settings

Settings form.

1 string reference to 'ctools_path_visibility_ctools_access_settings'
path_visibility.inc in plugins/access/path_visibility.inc

File

plugins/access/path_visibility.inc, line 21

Code

function ctools_path_visibility_ctools_access_settings($form, &$form_state, $conf) {
    $form['settings']['note'] = array(
        '#value' => '<div class="description">' . t('Note: if no context is chosen, the current page path will be used.') . '</div>',
    );
    $form['settings']['visibility_setting'] = array(
        '#type' => 'radios',
        '#options' => array(
            1 => t('Allow access on the following pages'),
            0 => t('Allow access on all pages except the following pages'),
        ),
        '#default_value' => $conf['visibility_setting'],
    );
    $form['settings']['paths'] = array(
        '#type' => 'textarea',
        '#title' => t('Paths'),
        '#default_value' => $conf['paths'],
        '#description' => t("Enter one page per line as Drupal paths. The '*' character is a wildcard. Example paths are %blog for the blog page and %blog-wildcard for every personal blog. %front is the front page.", array(
            '%blog' => 'blog',
            '%blog-wildcard' => 'blog/*',
            '%front' => '<front>',
        )),
    );
    return $form;
}