Overview
Comment: | Merge stable |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA1: |
59f0acd3562b09c8649c2a0f32a560b7 |
User & Date: | bohwaz on 2013-06-08 08:25:17 |
Other Links: | manifest | tags |
Context
2013-06-08
| ||
09:11 | Merge 0.5.4 check-in: 8d9bbb17fd user: bohwaz tags: trunk | |
08:25 | Merge stable check-in: 59f0acd356 user: bohwaz tags: trunk | |
08:24 | Correction recherche numéro téléphone [cd3c4650bf] check-in: 56382af0c1 user: bohwaz tags: stable, 0.5.4 | |
08:10 | Merge avec stable check-in: f90c3ac859 user: bohwaz tags: trunk | |
Changes
Modified include/class.membres.php from [aac365d475] to [894265f106].
︙ | ︙ | |||
265 266 267 268 269 270 271 | } elseif ($config['type'] == 'url' && !filter_var($data[$key], FILTER_VALIDATE_URL)) { throw new UserException('Adresse URL invalide dans le champ "' . $config['title'] . '".'); } elseif ($config['type'] == 'tel') { | | | 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 | } elseif ($config['type'] == 'url' && !filter_var($data[$key], FILTER_VALIDATE_URL)) { throw new UserException('Adresse URL invalide dans le champ "' . $config['title'] . '".'); } elseif ($config['type'] == 'tel') { $data[$key] = utils::normalizePhoneNumber($data[$key]); } elseif ($config['type'] == 'country') { $data[$key] = strtoupper(substr($data[$key], 0, 2)); } elseif ($config['type'] == 'checkbox') { |
︙ | ︙ | |||
484 485 486 487 488 489 490 491 492 493 494 495 496 497 | $champ = $champs->get($field); if ($champ['type'] == 'multiple') { $where = 'WHERE '.$field.' & (1 << '.(int)$query.')'; $order = false; } elseif (!$champs->isText($field)) { $where = 'WHERE '.$field.' = \''.$db->escapeString($query).'\''; $order = $field; } else | > > > > > > > > > > > > > | 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 | $champ = $champs->get($field); if ($champ['type'] == 'multiple') { $where = 'WHERE '.$field.' & (1 << '.(int)$query.')'; $order = false; } elseif ($champ['type'] == 'tel') { $query = utils::normalizePhoneNumber($query); $query = preg_replace('!^0+!', '', $query); if ($query == '') { return false; } $where = 'WHERE '.$field.' LIKE \'%'.$db->escapeString($query).'\''; $order = $field; } elseif (!$champs->isText($field)) { $where = 'WHERE '.$field.' = \''.$db->escapeString($query).'\''; $order = $field; } else |
︙ | ︙ |
Modified include/lib.utils.php from [ac227a55ca] to [94c20dd0d3].
︙ | ︙ | |||
485 486 487 488 489 490 491 | } static public function checkBIC($bic) { return preg_match('!^[A-Z]{4}[A-Z]{2}[1-9A-Z]{2}(?:[A-Z\d]{3})?$!', $bic); } | > > > > > > | | 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 | } static public function checkBIC($bic) { return preg_match('!^[A-Z]{4}[A-Z]{2}[1-9A-Z]{2}(?:[A-Z\d]{3})?$!', $bic); } static public function normalizePhoneNumber($n) { $n = preg_replace('![^\d\+]!', '', $n); return $n; } static public function json_readable_encode($in, $indent = 0, Closure $_escape = null) { if (__CLASS__ && isset($this)) { $_myself = array($this, __FUNCTION__); } elseif (__CLASS__) { |
︙ | ︙ |