Commit e5bf68ad authored by Leigh B. Stoller's avatar Leigh B. Stoller
Browse files

Add some unrelated missing functions that are still pending in my

devel tree.
parent 5019322b
......@@ -160,6 +160,12 @@ function TBvalid_gid($gid) {
return (strlen($gid) <= $TBDB_GIDLEN) && (strlen($gid) >= $TBDB_MINLEN) &&
preg_match("/^[a-zA-Z][-\w]+$/", $gid);
}
function TBvalid_eid($eid) {
global $TBDB_EIDLEN, $TBDB_MINLEN;
return (strlen($eid) <= $TBDB_EIDLEN) && (strlen($eid) >= $TBDB_MINLEN) &&
preg_match("/^[a-zA-Z][-\w]+$/", $eid);
}
function TBvalid_phone($phone) {
global $TBDB_PHONELEN;
......@@ -172,6 +178,10 @@ function TBvalid_usrname($name) {
return (strlen($name) <= $TBDB_USRNAMELEN) &&
preg_match("/^[-\w\. ]+$/", $name);
}
function TBvalid_description($token) {
return (strlen($token) <= 256) &&
preg_match("/^[\\040-\\176]*$/", $token);
}
function TBvalid_email($email)
{
global $TBDB_EMAILLEN, $TBDB_MINLEN;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment