Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Comparing changes

Choose two branches to see what's changed or to start a new pull request. If you need to, you can also compare across forks.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also compare across forks.
base fork: jas-/software-licensing
base: f51ff5a412
...
head fork: jas-/software-licensing
compare: 556d454911
Checking mergeability… Don't worry, you can still create the pull request.
  • 2 commits
  • 2 files changed
  • 0 commit comments
  • 1 contributor
Showing with 5 additions and 5 deletions.
  1. +3 −2 models/model.users.php
  2. +2 −3 models/model.validation.php
View
5 models/model.users.php
@@ -96,6 +96,7 @@ public function __do($obj)
if (!empty($d['do'])){
switch($d['do']){
case 'add':
+ echo '<pre>'; print_r($d); echo '</pre>';
$x = $this->registry->libs->JSONEncode($this->__addUser($d));
break;
case 'edit':
@@ -160,8 +161,8 @@ private function __valFormat($details)
($this->registry->val->type($details['confirm'], 'special')) ||
($this->registry->val->type($details['level'], 'alpha')) ||
($this->registry->val->type($details['group'], 'alpha')) ||
- ($this->registry->val->type($details['organizationalName'], 'paragraph')) ||
- ($this->registry->val->type($details['organizationalUnitName'], 'paragraph')) ||
+ ($this->registry->val->type($details['organizationalName'], 'special')) ||
+ ($this->registry->val->type($details['organizationalUnitName'], 'special')) ||
($this->registry->val->type($details['localityName'], 'alpha')) ||
($this->registry->val->type($details['stateOrProvinceName'], 'string')) ||
($this->registry->val->type($details['countryName'], 'string')));
View
5 models/model.validation.php
@@ -166,9 +166,8 @@ public function type($v, $t)
if (!empty($v)) {
switch($t) {
case 'special':
- return (filter_var($v, FILTER_VALIDATE_REGEXP, array('options'=>array('regexp'=>'/^[a-z0-9-_~!@#$%^&*()_+{}|\;:"\'<>?]{1,128}$/Di')))) ? true : false;
- case 'paragraph':
- return (filter_var($v, FILTER_VALIDATE_REGEXP, array('options'=>array('regexp'=>'/^[a-z0-9 -_~!@#$%^&*()_+{}|\;:"\'<>?]{1,128}$/Di')))) ? true : false;
+ //return (!filter_var($v, FILTER_VALIDATE_REGEXP, array('options'=>array('regexp'=>'/^[\S+\d+\s+-_~!@#$%^&*()_+{}|\;:"\'<>?]{1,128}$/Di')))) ? false : true;
+ return (filter_var($v, FILTER_VALIDATE_REGEXP, array('options'=>array('regexp'=>'/^\d+\w+\s+\D+\W+\S+{1,128}$/Di')))) ? true : false;
case 'integer':
return (filter_var($value, FILTER_VALIDATE_REGEXP, array('options'=>array('regexp'=>'/^[0-9]{1,128}$/Di')))) ? true : false;
case 'string':

No commit comments for this range

Something went wrong with that request. Please try again.