diff options
author | webchick <webchick@24967.no-reply.drupal.org> | 2011-12-24 18:09:18 -0800 |
---|---|---|
committer | webchick <webchick@24967.no-reply.drupal.org> | 2011-12-24 18:09:18 -0800 |
commit | 88b568e272e3776ef217bed4059249f9f62abec3 (patch) | |
tree | 5fadf9223182b8d253861ae1bda721cf3ffda9a6 /includes | |
parent | 862cfa277446efe0125bd3e40335bcbbebf55299 (diff) | |
download | brdo-88b568e272e3776ef217bed4059249f9f62abec3.tar.gz brdo-88b568e272e3776ef217bed4059249f9f62abec3.tar.bz2 |
Issue #381994 by xjm, good_man, elcuco, brianV, yhager: Fixed Machine-name fields are always in Latin characters, and should therefore always be LTR.
Diffstat (limited to 'includes')
-rw-r--r-- | includes/form.inc | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/includes/form.inc b/includes/form.inc index b0d0b4449..3d5f6f22e 100644 --- a/includes/form.inc +++ b/includes/form.inc @@ -3351,6 +3351,13 @@ function form_process_machine_name($element, &$form_state) { 'replace' => '_', ); + // By default, machine names are restricted to Latin alphanumeric characters. + // So, default to LTR directionality. + if (!isset($element['#attributes'])) { + $element['#attributes'] = array(); + } + $element['#attributes'] += array('dir' => 'ltr'); + // The source element defaults to array('name'), but may have been overidden. if (empty($element['#machine_name']['source'])) { return $element; |