mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-05-15 06:01:19 +00:00
fix validation of emails
This commit is contained in:
parent
525b6d45c9
commit
369497ee3a
|
@ -1233,7 +1233,8 @@ class SeedDMS_Core_AttributeDefinition { /* {{{ */
|
||||||
break;
|
break;
|
||||||
case self::type_email:
|
case self::type_email:
|
||||||
foreach($values as $value) {
|
foreach($values as $value) {
|
||||||
$success &= preg_match('/^[a-z0-9._-]+@+[a-z0-9._-]+\.+[a-z]{2,4}$/i', $value);
|
$success &= filter_var($value, FILTER_VALIDATE_EMAIL);
|
||||||
|
//preg_match('/^[a-z0-9._-]+@+[a-z0-9._-]+\.+[a-z]{2,63}$/i', $value);
|
||||||
}
|
}
|
||||||
if(!$success)
|
if(!$success)
|
||||||
$this->_validation_error = 5;
|
$this->_validation_error = 5;
|
||||||
|
|
|
@ -28,6 +28,7 @@
|
||||||
- add methods SeedDMS_Core_DocumentContent::getReviewers() and SeedDMS_Core_DocumentContent::getApprovers()
|
- add methods SeedDMS_Core_DocumentContent::getReviewers() and SeedDMS_Core_DocumentContent::getApprovers()
|
||||||
- add methods SeedDMS_Core_DocumentContent::getApproveLog() and SeedDMS_Core_DocumentContent::getReviewLog()
|
- add methods SeedDMS_Core_DocumentContent::getApproveLog() and SeedDMS_Core_DocumentContent::getReviewLog()
|
||||||
- better handling of document with an empty workflow state
|
- better handling of document with an empty workflow state
|
||||||
|
- fix checking of email addresses by using filter_var instead of regex
|
||||||
</notes>
|
</notes>
|
||||||
<contents>
|
<contents>
|
||||||
<dir baseinstalldir="SeedDMS" name="/">
|
<dir baseinstalldir="SeedDMS" name="/">
|
||||||
|
|
Loading…
Reference in New Issue
Block a user