function pathauto_clean_token_values

cis7 pathauto.inc pathauto_clean_token_values(&$replacements, $data = array(), $options = array())
cle7 pathauto.inc pathauto_clean_token_values(&$replacements, $data = array(), $options = array())
elmsmedia7 pathauto.inc pathauto_clean_token_values(&$replacements, $data = array(), $options = array())
icor7 pathauto.inc pathauto_clean_token_values(&$replacements, $data = array(), $options = array())
meedjum_blog7 pathauto.inc pathauto_clean_token_values(&$replacements, $data = array(), $options = array())
mooc7 pathauto.inc pathauto_clean_token_values(&$replacements, $data = array(), $options = array())

Clean tokens so they are URL friendly.

Parameters

$replacements: An array of token replacements that need to be "cleaned" for use in the URL.

$data: An array of objects used to generate the replacements.

$options: An array of options used to generate the replacements.

1 string reference to 'pathauto_clean_token_values'
pathauto_create_alias in sites/all/modules/ulmus/pathauto/pathauto.inc
Apply patterns to create an alias.

File

sites/all/modules/ulmus/pathauto/pathauto.inc, line 604
Miscellaneous functions for Pathauto.

Code

function pathauto_clean_token_values(&$replacements, $data = array(), $options = array()) {
  foreach ($replacements as $token => $value) {
    // Only clean non-path tokens.
    if (!preg_match('/(path|alias|url|url-brief)\]$/', $token)) {
      $replacements[$token] = pathauto_cleanstring($value);
    }
  }
}
Error | ELMSLN API

Error

×

Error message

  • Warning: Cannot modify header information - headers already sent by (output started at /var/www/html/elmsln_community/api.elmsln.org/includes/common.inc:2791) in drupal_send_headers() (line 1499 of /var/www/html/elmsln_community/api.elmsln.org/includes/bootstrap.inc).
  • Error: Call to undefined function apc_delete() in DrupalAPCCache->clear() (line 289 of /var/www/html/elmsln_community/api.elmsln.org/sites/all/modules/apc/drupal_apc_cache.inc).
The website encountered an unexpected error. Please try again later.