Index: INSTALL.txt =================================================================== RCS file: /cvs/drupal-contrib/contributions/modules/pathauto/INSTALL.txt,v retrieving revision 1.3 diff -u -p -r1.3 INSTALL.txt --- INSTALL.txt 21 Jun 2008 18:20:38 -0000 1.3 +++ INSTALL.txt 22 Jun 2008 19:31:14 -0000 @@ -18,14 +18,12 @@ sure "administer pathauto" is enabled th **Transliteration support: If you desire transliteration support in the creation of URLs (e.g. the -replacement of À with A) then you will need to rename the file -i18n-ascii.example.txt to i18n-ascii.txt +replacement of Á with A) then you will need to install the Transliteration +module, which can be found at http://drupal.org/project/transliteration -You can then freely edit the i18n-ascii.txt without worrying that your changes -will be over-written by upgrades of Pathauto. - -For details on how to transliterate any UTF8 character, please see the full -i18n-ascii-fill.txt file information at http://drupal.org/node/185664 +Once you've installed and enabled the module, simply go to +admin/build/path/pathauto and check the "Transliterate prior to creating alias" +box and path aliases should now be transliterated automagically. **Upgrading from previous versions: If you are upgrading from Pathauto 5.x-1.x to 5.x-2.x (or 6.x-2.x) then you Index: pathauto.admin.inc =================================================================== RCS file: /cvs/drupal-contrib/contributions/modules/pathauto/pathauto.admin.inc,v retrieving revision 1.10 diff -u -p -r1.10 pathauto.admin.inc --- pathauto.admin.inc 10 Jun 2008 21:41:53 -0000 1.10 +++ pathauto.admin.inc 22 Jun 2008 19:31:15 -0000 @@ -115,10 +115,10 @@ function pathauto_admin_settings() { $disable_transliteration = TRUE; $path = drupal_get_path('module', 'pathauto'); - $transliteration_help = t('When a pattern includes certain characters (such as those with accents) should Pathauto attempt to transliterate them into the ASCII-96 alphabet? Transliteration is determined by the i18n-ascii.txt file in the Pathauto directory. This option is disabled on your site because you do not have an i18n-ascii.txt file in the Pathauto directory.'); - if (is_file($path .'/i18n-ascii.txt')) { + $transliteration_help = t("When a pattern includes certain characters (such as those with accents) should Pathauto attempt to transliterate them into the ASCII-96 alphabet? Transliteration is handled by the Transliteration module. This option is disabled on your site because the Translation module either isn't installed, or isn't installed properly."); + if (module_exists('transliteration')) { $disable_transliteration = FALSE; - $transliteration_help = t('When a pattern includes certain characters (such as those with accents) should Pathauto attempt to transliterate them into the ASCII-96 alphabet? Transliteration is determined by the i18n-ascii.txt file in the Pathauto directory.'); + $transliteration_help = t('When a pattern includes certain characters (such as those with accents) should Pathauto attempt to transliterate them into the ASCII-96 alphabet? Transliteration is handled by the Transliteration module.'); } else { // Perhaps they've removed the file, set the transliterate option to FALSE Index: pathauto.inc =================================================================== RCS file: /cvs/drupal-contrib/contributions/modules/pathauto/pathauto.inc,v retrieving revision 1.45 diff -u -p -r1.45 pathauto.inc --- pathauto.inc 18 Jun 2008 20:02:40 -0000 1.45 +++ pathauto.inc 22 Jun 2008 19:31:15 -0000 @@ -155,20 +155,14 @@ function pathauto_cleanstring($string, $ $output = str_replace('/', '', $output); } - // Optionally remove accents and transliterate + // Optionally transliterate (by running through the Transliteration module) if (variable_get('pathauto_transliterate', FALSE)) { - static $i18n_loaded = false; - static $translations = array(); - - if (!$i18n_loaded) { - $path = drupal_get_path('module', 'pathauto'); - if (is_file($path .'/i18n-ascii.txt')) { - $translations = parse_ini_file($path .'/i18n-ascii.txt'); - } - $i18n_loaded = true; + if (module_exists('transliteration')) { + $output = transliteration_get($output); + } + else { + drupal_set_message(t('Pathauto could not transliterate the path, as the Transliteration module has been disabled.'), 'error'); } - - $output = strtr($output, $translations); } // Reduce to the subset of ASCII96 letters and numbers