summaryrefslogtreecommitdiff
path: root/php
diff options
context:
space:
mode:
authorThomas Arendsen Hein <thomas@intevation.de>2008-06-02 15:43:34 (GMT)
committerThomas Arendsen Hein <thomas@intevation.de>2008-06-02 15:43:34 (GMT)
commit1348765a6e2675576f8a05c01d089048d5151013 (patch)
tree52cb9ebcfc5cef8b495af66bfa2a6b9ff849bd0b /php
parent0f8557ecec5ab7afef1ba824e7509a5fc632ab77 (diff)
downloadkolab-webadmin-1348765a6e2675576f8a05c01d089048d5151013.tar.gz
Fix kolab/issue2739 (Some characters are not allowed in users fax-/phonenumbers despite the description in the error)
Space was missing from the regular expression and the minus sign has to be at the beginning or the end of [...] side note 1: the \ before / is really needed side note 2: php-kolab/Kolab_Webadmin/Webadmin/form.class.php seems unused, but I fixed it, too, to avoid copy&paste errors in the future.
Diffstat (limited to 'php')
-rw-r--r--php/admin/include/form.class.php2
-rw-r--r--php/admin/locale/de/LC_MESSAGES/messages.po6
2 files changed, 4 insertions, 4 deletions
diff --git a/php/admin/include/form.class.php b/php/admin/include/form.class.php
index cdb6a53..38751f1 100644
--- a/php/admin/include/form.class.php
+++ b/php/admin/include/form.class.php
@@ -52,7 +52,7 @@ function checkquota( $form, $key, $value )
function checkphone( $form, $key, $value )
{
if( empty($value) ) return ''; // OK
- else if( !preg_match('/^[a-zA-Z0-9()-+\/.=?:]*$/',$value) ) return _('Phone entries may only contain a-z, numbers and the characters ()-+/.=?:');
+ else if( !preg_match('/^[a-zA-Z0-9 ()+\/.=?:-]*$/',$value) ) return _('Phone entries may only contain a-z, numbers, spaces and the characters ()-+/.=?:');
else return '';
}
diff --git a/php/admin/locale/de/LC_MESSAGES/messages.po b/php/admin/locale/de/LC_MESSAGES/messages.po
index 982cd43..0cd399a 100644
--- a/php/admin/locale/de/LC_MESSAGES/messages.po
+++ b/php/admin/locale/de/LC_MESSAGES/messages.po
@@ -8,7 +8,7 @@ msgstr ""
"Project-Id-Version: Kolab-Webadmin German\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2008-04-10 12:58+0200\n"
-"PO-Revision-Date: 2008-02-26 16:51+0100\n"
+"PO-Revision-Date: 2008-06-02 17:40+0200\n"
"Last-Translator: Thomas Arendsen Hein <thomas@intevation.de>\n"
"Language-Team: Kolab development coordination <kolab-devel@kolab.org>\n"
"MIME-Version: 1.0\n"
@@ -2146,9 +2146,9 @@ msgstr "Plattenplatz muss eine ganze Zahl sein"
#: ../include/form.class.php:55
msgid ""
-"Phone entries may only contain a-z, numbers and the characters ()-+/.=?:"
+"Phone entries may only contain a-z, numbers, spaces and the characters ()-+/.=?:"
msgstr ""
-"Telefonnummern dürfen nur A-Z, Ziffern und die Zeichen ()-+/.=?: enthalten."
+"Telefonnummern dürfen nur a-z, Ziffern, Leerzeichen und die Zeichen ()-+/.=?: enthalten."
#: ../include/form.class.php:118
msgid "<tr><th>Attribute</th><th>Value</th><th>Comment</th></tr>"