You are here

function shortcut_link_edit_validate in Drupal 7

Validation handler for the shortcut link add and edit forms.

1 string reference to 'shortcut_link_edit_validate'
_shortcut_link_form_elements in modules/shortcut/shortcut.admin.inc
Helper function for building a form for adding or editing shortcut links.

File

modules/shortcut/shortcut.admin.inc, line 512
Administrative page callbacks for the shortcut module.

Code

function shortcut_link_edit_validate($form, &$form_state) {
  if (!shortcut_valid_link($form_state['values']['shortcut_link']['link_path'])) {
    form_set_error('shortcut_link][link_path', t('The link must correspond to a valid path on the site.'));
  }
}