finder_admin_edit_validate

  1. finder
    1. 6.x-1.x
    2. 7.x-1.x
Versions
6.x-1.x – 7.x-1.x finder_admin_edit_validate($form, &$form_state)

Validate function for admin finder add/edit page.

Code

includes/finder.admin.inc, line 472

<?php
function finder_admin_edit_validate($form, &$form_state) {
  $values = &$form_state['values'];
  $arg_sep = preg_replace("/[\/\-\_\s]/", "", $values['settings']['advanced']['arg_sep']);
  if (!$arg_sep) {
    form_set_error('arg_sep', t('Multiple value URL arguments separator must contain at least one character that is not a space ( ), forward-slash (/), hyphen (-), or underscore (_).'));
  }
  if (!empty($values['settings']['advanced']['empty_symbol'])) {
    $empty_symbol = preg_replace("/[\/\-\_\s]/", "", $values['settings']['advanced']['empty_symbol']);
    if (!$empty_symbol) {
      form_set_error('arg_sep', t('Empty value URL arguments symbol must contain at least one character that is not a space ( ), forward-slash (/), hyphen (-), or underscore (_).'));
    }
    if ($arg_sep == $empty_symbol) {
      form_set_error('empty_symbol', t('The "empty value URL arguments symbol" should not be the same as the "multiple value URL arguments separator".'));
    }
  }
}
?>

Comments

bFqBXqglWkPMWoBJJoz

There's nothing like the rleief of finding what you're looking for.

Post new comment

  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd>
  • Lines and paragraphs break automatically.

More information about formatting options

Type the characters you see in this picture. (verify using audio)
Type the characters you see in the picture above; if you can't read them, submit the form and a new image will be generated. Not case sensitive.